StoreProduct class

Contains all the product details associated with a StoreProduct

Annotations
  • @freezed

Constructors

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

Properties

copyWith → $StoreProductCopyWith<StoreProduct>
no setterinherited
currencyCode String
Currency code for price and original price.
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
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
runtimeType Type
A representation of the runtime type of the object.
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>
inherited
toString() String
A string representation of this object.
inherited

Operators

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