Interface IStoreListener
Implemented by Application developers using Unity Purchasing.
Namespace: UnityEngine.Purchasing
Syntax
public interface IStoreListener
Methods
OnInitialized(IStoreController, IExtensionProvider)
Purchasing initialized successfully.
The IStoreController
and IExtensionProvider
are
available for accessing purchasing functionality.
Declaration
void OnInitialized(IStoreController controller, IExtensionProvider extensions)
Parameters
Type | Name | Description |
---|---|---|
IStoreController | controller | The |
IExtensionProvider | extensions | The |
OnInitializeFailed(InitializationFailureReason)
Purchasing failed to initialise for a non recoverable reason.
Declaration
void OnInitializeFailed(InitializationFailureReason error)
Parameters
Type | Name | Description |
---|---|---|
InitializationFailureReason | error | The failure reason. |
OnPurchaseFailed(Product, PurchaseFailureReason)
A purchase failed with specified reason.
Declaration
void OnPurchaseFailed(Product product, PurchaseFailureReason failureReason)
Parameters
Type | Name | Description |
---|---|---|
Product | product | The product that was attempted to be purchased. |
PurchaseFailureReason | failureReason | The failure reason. |
ProcessPurchase(PurchaseEventArgs)
A purchase succeeded.
Declaration
PurchaseProcessingResult ProcessPurchase(PurchaseEventArgs purchaseEvent)
Parameters
Type | Name | Description |
---|---|---|
PurchaseEventArgs | purchaseEvent | The |
Returns
Type | Description |
---|---|
PurchaseProcessingResult | The result of the successful purchase |