public interface PurchaseCallback
Modifier and Type | Method and Description |
---|---|
void |
itemPurchased(String sku)
Indicates a the given SKU was purchased by a user.
|
void |
itemPurchaseError(String sku,
String errorMessage)
Callback indicating a the given SKU purchase failed
|
void |
itemRefunded(String sku)
Deprecated.
This callback is no longer used. Use the Receipts API to check if the user currently "owns" a product. See https://www.codenameone.com/blog/intro-to-in-app-purchase.html for a guide
into how to set up in-app purchase for all scenarios including subscriptions.
|
void |
paymentFailed(String paymentCode,
String failureReason)
Indicates that a manual payment has failed
|
void |
paymentSucceeded(String paymentCode,
double amount,
String currency)
Indicates that a manual payment has passed
|
void |
subscriptionCanceled(String sku)
Deprecated.
Subscriptions should be handled directly in the associated store (iOS/Google Play, etc..). See https://www.codenameone.com/blog/intro-to-in-app-purchase.html for a guide
into how to set up in-app purchase for all scenarios including subscriptions.
|
void |
subscriptionStarted(String sku)
Deprecated.
Subscriptions should be handled directly in the associated store (iOS/Google Play, etc..). See https://www.codenameone.com/blog/intro-to-in-app-purchase.html for a guide
into how to set up in-app purchase for all scenarios including subscriptions.
|
void itemPurchased(String sku)
sku
- the sku purchasedvoid itemPurchaseError(String sku, String errorMessage)
sku
- the idvoid itemRefunded(String sku)
sku
- the sku purchasedvoid subscriptionStarted(String sku)
sku
- the sku purchasedvoid subscriptionCanceled(String sku)
sku
- the sku purchasedvoid paymentFailed(String paymentCode, String failureReason)
paymentCode
- the transaction id of the payment