SubscriptionOption class

Contains all details associated with a SubscriptionOption Used only for Google

Annotations
  • @freezed

Constructors

SubscriptionOption(String id, String storeProductId, String productId, List<PricingPhase> pricingPhases, List<String> tags, bool isBasePlan, Period? billingPeriod, bool isPrepaid, PricingPhase? fullPricePhase, PricingPhase? freePhase, PricingPhase? introPhase, String? presentedOfferingIdentifier)
const
factory
SubscriptionOption.fromJson(Map<String, dynamic> json)
factory

Properties

billingPeriod Period?
The subscription period of fullPricePhase (after free and intro trials).
no setterinherited
copyWith → $SubscriptionOptionCopyWith<SubscriptionOption>
no setterinherited
freePhase PricingPhase?
The free trial PricingPhase of the subscription. Looks for the first pricing phase of the SubscriptionOption where amountMicros is 0. There can be a freeTrialPhase and an introductoryPhase in the same SubscriptionOption.
no setterinherited
fullPricePhase PricingPhase?
The full price PricingPhase of the subscription. Looks for the last price phase of the SubscriptionOption.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
id String
Identifier of the subscription option If this SubscriptionOption represents a base plan, this will be the basePlanId. If it represents an offer, it will be {basePlanId}:{offerId}
no setterinherited
introPhase PricingPhase?
The intro trial PricingPhase of the subscription. Looks for the first pricing phase of the SubscriptionOption where amountMicros is greater than 0. There can be a freeTrialPhase and an introductoryPhase in the same SubscriptionOption.
no setterinherited
isBasePlan bool
True if this SubscriptionOption represents a Google subscription base plan (rather than an offer).
no setterinherited
isPrepaid bool
True if the subscription is pre-paid.
no setterinherited
presentedOfferingIdentifier String?
no setterinherited
pricingPhases List<PricingPhase>
Pricing phases defining a user's payment plan for the product over time.
no setterinherited
productId String
Identifer of the subscription associated with this SubsriptionOption This will be {subId}
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
storeProductId String
Identifier of the StoreProduct associated with this SubscriptionOption This will be {subId}:{basePlanId}
no setterinherited
tags List<String>
Tags defined on the base plan or offer.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited