InAppPurchaseData class
Represents details about purchased product.
Constructors
- InAppPurchaseData.new({bool? autoRenewing, String? orderId, String? packageName, int? applicationId, int? kind, String? productId, String? productName, int? purchaseTime, int? purchaseTimeMillis, int? purchaseState, String? developerPayload, String? purchaseToken, int? consumptionState, int? confirmed, String? currency, int? price, String? country, String? payOrderId, String? payType, int? purchaseType, String? lastOrderId, String? productGroup, int? oriPurchaseTime, String? subscriptionId, int? quantity, int? daysLasted, int? numOfPeriods, int? numOfDiscounts, int? expirationDate, int? expirationIntent, int? retryFlag, int? introductoryFlag, int? trialFlag, int? cancelTime, int? cancelReason, String? appInfo, int? notifyClosed, int? renewStatus, bool? subIsvalid, int? cancelledSubKeepDays, String? developerChallenge, int? deferFlag, String? oriSubscriptionId, int? cancelWay, int? cancellationTime, int? resumeTime, int? accountFlag, int? priceConsentStatus, int? renewPrice, int? graceExpirationTime})
- Creates an InAppPurchaseData object.
- InAppPurchaseData.fromJson(String str)
-
Creates an InAppPurchaseData object from a JSON string.
factory
- InAppPurchaseData.fromMap(Map json)
-
factory
Properties
- accountFlag ↔ int?
-
Account type.
getter/setter pair
- appInfo ↔ String?
-
App information, which is reserved.
getter/setter pair
- applicationId ↔ int?
-
ID of an app that initiates a purchase.
getter/setter pair
- autoRenewing ↔ bool?
-
Indicates whether the subscription is automatically renewed.
getter/setter pair
- cancellationTime ↔ int?
-
Subscription cancellation time in UTC.
getter/setter pair
- cancelledSubKeepDays ↔ int?
-
Number of days for retaining a subscription relationship after the subscription is canceled.
getter/setter pair
- cancelReason ↔ int?
-
Reason why a subscription is canceled.
getter/setter pair
- cancelTime ↔ int?
-
Subscription cancellation timestamp.
getter/setter pair
- cancelWay ↔ int?
-
Subscription cancellation initiator.
getter/setter pair
- confirmed ↔ int?
-
Confirmation.
getter/setter pair
- consumptionState ↔ int?
-
Consumption status, which is valid only for one-off products.
getter/setter pair
- country ↔ String?
-
Country or region code of a user service area.
getter/setter pair
- currency ↔ String?
-
Currency.
getter/setter pair
- daysLasted ↔ int?
-
Days of a paid subscription, excluding the free trial period and promotion period.
getter/setter pair
- deferFlag ↔ int?
-
Indicates whether to postpone the settlement date.
getter/setter pair
- developerChallenge ↔ String?
-
Challenge defined when an app initiates a consumption request, which uniquely identifies the consumption request.
getter/setter pair
- developerPayload ↔ String?
-
Reserved information on the merchant side, which is passed by the app during payment.
getter/setter pair
- expirationDate ↔ int?
-
Subscription expiration timestamp.
getter/setter pair
- expirationIntent ↔ int?
-
Reason why a subscription expires.
getter/setter pair
- graceExpirationTime ↔ int?
-
Obtains a timestamp when a grace period ends.
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setteroverride
- introductoryFlag ↔ int?
-
Indicates whether a subscription is in the renewal period with promotion.
getter/setter pair
- kind ↔ int?
-
Product type.
getter/setter pair
- lastOrderId ↔ String?
-
Order ID generated by the Huawei IAP server during fee deduction on the previous renewal.
getter/setter pair
- notifyClosed ↔ int?
-
Indicates whether a user has disabled the subscription notification function.
getter/setter pair
- numOfDiscounts ↔ int?
-
Number of successful renewal periods with promotion.
getter/setter pair
- numOfPeriods ↔ int?
-
Number of successful standard renewal periods (that is, renewal periods without promotion).
getter/setter pair
- orderId ↔ String?
-
Order ID on the Huawei IAP server, which uniquely identifies a transaction and is generated by the Huawei IAP server during payment.
getter/setter pair
- oriPurchaseTime ↔ int?
-
First fee deduction timestamp since 00:00:00 on January 1, 1970, in millionseconds.
getter/setter pair
- oriSubscriptionId ↔ String?
-
Original subscription ID.
getter/setter pair
- packageName ↔ String?
-
Software package name of the app that initiates a purchase.
getter/setter pair
- payOrderId ↔ String?
-
Merchant ID, which uniquely identifies a transaction and is generated by the Huawei IAP server during payment.
getter/setter pair
- payType ↔ String?
-
Payment method.
getter/setter pair
- price ↔ int?
-
Value after the actual price of a product is multiplied by 100.
getter/setter pair
- priceConsentStatus ↔ int?
-
User opinion on the price increase of a product.
getter/setter pair
- productGroup ↔ String?
-
ID of the subscription group to which a subscription belongs.
getter/setter pair
- productId ↔ String?
-
Product ID.
getter/setter pair
- productName ↔ String?
-
Product name.
getter/setter pair
- purchaseState ↔ int?
-
Order status.
getter/setter pair
- purchaseTime ↔ int?
-
Purchase time.
getter/setter pair
- purchaseTimeMillis ↔ int?
-
Purchase timestamp from 00:00:00 on January 1, 1970 to the purchase time, in millionseconds.
getter/setter pair
- purchaseToken ↔ String?
-
Purchase token, which uniquely identifies the mapping between a product and a user.
getter/setter pair
- purchaseType ↔ int?
-
Purchase type.
getter/setter pair
- quantity ↔ int?
-
Purchase quantity.
getter/setter pair
- renewPrice ↔ int?
-
Renewal price.
getter/setter pair
- renewStatus ↔ int?
-
Renewal status.
getter/setter pair
- resumeTime ↔ int?
-
Time when a subscription is resumed.
getter/setter pair
- retryFlag ↔ int?
-
Indicates whether the system still tries to renew an expired subscription.
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- subIsvalid ↔ bool?
-
true
: A user has been charged for a product, the product has not expired, and no refund has been made. In this case, you can provide services for the user.false
: The purchase of a product is not finished, the product has expired, or a refund has been made for the product after the subscription is valid.getter/setter pair - subscriptionId ↔ String?
-
Subscription ID.
getter/setter pair
- trialFlag ↔ int?
-
Indicates whether a subscription is in the free trial period.
getter/setter pair
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → String -
toMap(
) → Map< String, dynamic> -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override