| Package | com.myflashlab.air.extensions.billing |
| Class | public class Purchase |
| Inheritance | Purchase Object |
The Purchase class holds information about payments. Each time a payment is made in your app, an instance of this class will be initialized while holding information about the successful payment transaction.
Besides that, when you call Billing.getPurchases() the current purchased items by the user will be
returned in an Array holding objects of this class type. But you should take into the consideration that the
property billingType is never saved in the local cache or Google's/Apple's servers so they are not
accessible through the restoring process.
See also
| Property | Defined By | ||
|---|---|---|---|
| autoRenewing : Boolean [read-only]
(Android)
| Purchase | ||
| billingType : int [read-only]
After a successful payment operation, this value will be one of the following types, BillingType.PERMANENT, BillingType.CONSUMABLE or
BillingType.AUTO_RENEWAL.
NOTICE: This property value is NOT saved in the cache. | Purchase | ||
| developerPayload : String [read-only] | Purchase | ||
| isAcknowledged : Boolean [read-only]
(Android) Indicates whether the purchase has been acknowledged. | Purchase | ||
| orderId : String [read-only]
order id is a unique string which identifies the order. | Purchase | ||
| originalOrderId : String [read-only]
(iOS)
| Purchase | ||
| productId : String [read-only]
A string used to identify a product that can be purchased from within your application.
| Purchase | ||
| purchaseState : int [read-only]
The purchase state of the order. | Purchase | ||
| purchaseTime : Number [read-only]
The time the product was purchased, in milliseconds since the epoch (Jan 1, 1970).
| Purchase | ||
| purchaseToken : String [read-only]
Transaction identifier or purchase token is a unique string which identifies a successful payment
transaction. | Purchase | ||
| rawData : String [read-only]
Indicates the original data returned with a purchase result. | Purchase | ||
| signature : String [read-only]
(Android) Purchase signature returned with a successful purchase. | Purchase | ||
| autoRenewing | property |
autoRenewing:Boolean [read-only] (Android)
public function get autoRenewing():Boolean| billingType | property |
billingType:int [read-only]
After a successful payment operation, this value will be one of the following types, BillingType.PERMANENT, BillingType.CONSUMABLE or
BillingType.AUTO_RENEWAL.
NOTICE: This property value is NOT saved in the cache. Meaning that when you restore your products or call Billing.getPurchases() you will always
receive -1 for this value. you can use this value ONLY when the purchase result is returned as a successful operation.
public function get billingType():intSee also
| developerPayload | property |
developerPayload:String [read-only] public function get developerPayload():String| isAcknowledged | property |
isAcknowledged:Boolean [read-only] (Android) Indicates whether the purchase has been acknowledged.
public function get isAcknowledged():Boolean| orderId | property |
orderId:String [read-only]
order id is a unique string which identifies the order. on iOS platform, this value is equal to purchaseToken
public function get orderId():StringSee also
| originalOrderId | property |
originalOrderId:String [read-only] (iOS)
public function get originalOrderId():String| productId | property |
productId:String [read-only]
A string used to identify a product that can be purchased from within your application.
public function get productId():String| purchaseState | property |
purchaseState:int [read-only]
The purchase state of the order. On Android, possible values are 0 (purchased), 1 (canceled), or 2 (refunded) but on iOS it will always be 0 (purchased)
public function get purchaseState():int| purchaseTime | property |
purchaseTime:Number [read-only]
The time the product was purchased, in milliseconds since the epoch (Jan 1, 1970).
public function get purchaseTime():Number| purchaseToken | property |
purchaseToken:String [read-only]
Transaction identifier or purchase token is a unique string which identifies a successful payment transaction. you may wish to save this value for your later references. For example when forceConsuming a product on Android, you need to pass this Token to the forceConsume method.
public function get purchaseToken():String| rawData | property |
rawData:String [read-only] Indicates the original data returned with a purchase result.
public function get rawData():String| signature | property |
signature:String [read-only] (Android) Purchase signature returned with a successful purchase.
public function get signature():String