StoreProduct class

Contains all the product details associated with a StoreProduct

Available extensions
Annotations
  • @freezed

Constructors

StoreProduct(String identifier, String description, String title, double price, String priceString, String currencyCode, {@JsonKey(name: 'introPrice') IntroductoryPrice? introductoryPrice, List<StoreProductDiscount>? discounts, ProductCategory? productCategory, SubscriptionOption? defaultOption, List<SubscriptionOption>? subscriptionOptions, PresentedOfferingContext? presentedOfferingContext, String? subscriptionPeriod})
const
factory
StoreProduct.fromJson(Map<String, dynamic> json)
factory

Properties

copyWith → $StoreProductCopyWith<StoreProduct>
Create a copy of StoreProduct with the given fields replaced by the non-null parameter values.
no setterinherited
currencyCode String
Currency code for price and original price.
no setterinherited
defaultOption SubscriptionOption?
Default subscription option for a product. Google Play only.
no setterinherited
description String
Description of the product.
no setterinherited
discounts List<StoreProductDiscount>?
Collection of discount offers for a product. Null for Android.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
identifier String
Product Id.
no setterinherited
introductoryPrice IntroductoryPrice?
Introductory price for product. Can be null.
no setterinherited
presentedOfferingContext PresentedOfferingContext?
Offering context this package belongs to. Null if not using offerings or if fetched directly from store via getProducts
no setterinherited
price double
Price of the product in the local currency.
no setterinherited
priceString String
Formatted price of the item, including its currency sign.
no setterinherited
productCategory ProductCategory?
Product category.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
subscriptionOptions List<SubscriptionOption>?
Collection of subscription options for a product. Google Play only.
no setterinherited
subscriptionPeriod String?
Subscription period, specified in ISO 8601 format. For example, P1W equates to one week, P1M equates to one month, P3M equates to three months, P6M equates to six months, and P1Y equates to one year. Note: Not available for Amazon.
no setterinherited
title String
Title of the product.
no setterinherited

Methods

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

Operators

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