No Description
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

IStoreCallback.cs 2.7KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. using System;
  2. using System.Collections.Generic;
  3. namespace UnityEngine.Purchasing.Extension
  4. {
  5. /// <summary>
  6. /// Callback interface for <see cref="IStore"/>s.
  7. /// </summary>
  8. public interface IStoreCallback
  9. {
  10. /// <summary>
  11. /// For querying product information.
  12. /// </summary>
  13. ProductCollection products { get; }
  14. /// <summary>
  15. /// Purchasing unavailable.
  16. /// </summary>
  17. /// <param name="reason"> The reason the initialization failed. </param>
  18. [Obsolete]
  19. void OnSetupFailed(InitializationFailureReason reason);
  20. /// <summary>
  21. /// Purchasing unavailable.
  22. /// </summary>
  23. /// <param name="reason"> The reason the initialization failed. </param>
  24. /// <param name="message"> More information on the failure reason. </param>
  25. void OnSetupFailed(InitializationFailureReason reason, string message);
  26. /// <summary>
  27. /// Complete setup by providing a list of available products,
  28. /// complete with metadata and any associated purchase receipts
  29. /// and transaction IDs.
  30. ///
  31. /// Any previously unseen purchases will be completed by the PurchasingManager.
  32. /// </summary>
  33. /// <param name="products"> The list of product descriptions retrieved. </param>
  34. void OnProductsRetrieved(List<ProductDescription> products);
  35. /// <summary>
  36. /// Inform Unity Purchasing of a purchase.
  37. /// </summary>
  38. /// <param name="storeSpecificId"> The product id specific to the store it was purchased from. </param>
  39. /// <param name="receipt"> The receipt provided by the store detailing the purchase </param>
  40. /// <param name="transactionIdentifier"> The id of the transaction </param>
  41. void OnPurchaseSucceeded(string storeSpecificId, string receipt, string transactionIdentifier);
  42. /// <summary>
  43. /// Inform Unity Purchasing of all active purchases.
  44. /// </summary>
  45. /// <param name="purchasedProducts">all active purchased products</param>
  46. void OnAllPurchasesRetrieved(List<Product> purchasedProducts);
  47. /// <summary>
  48. /// Notify a failed purchase with associated details.
  49. /// </summary>
  50. /// <param name="desc"> The object detailing the purchase failure </param>
  51. void OnPurchaseFailed(PurchaseFailureDescription desc);
  52. /// <summary>
  53. /// Stores may opt to disable Unity IAP's transaction log if they offer a robust transaction
  54. /// system of their own (e.g. Apple).
  55. ///
  56. /// The default value is 'true'.
  57. /// </summary>
  58. bool useTransactionLog { get; set; }
  59. }
  60. }