CommercePlan class
Constructors
-
CommercePlan({required CommercePlanObjectEnum object, required String id, required String name, required CommerceMoneyResponse fee, required CommerceMoneyResponse? annualMonthlyFee, required CommerceMoneyResponse? annualFee, required String? description, required String productId, required bool isDefault, required bool isRecurring, required bool publiclyVisible, required bool hasBaseFee, required String forPayerType, required String slug, required String? avatarUrl, List<
FeatureResponse> features = const [], required bool freeTrialEnabled, required int? freeTrialDays}) - Returns a new CommercePlan instance.
Properties
- annualFee ↔ CommerceMoneyResponse?
-
getter/setter pair
- annualMonthlyFee ↔ CommerceMoneyResponse?
-
getter/setter pair
- avatarUrl ↔ String?
-
The URL of the plan's avatar image.
getter/setter pair
- description ↔ String?
-
The description of the plan.
getter/setter pair
-
features
↔ List<
FeatureResponse> -
The features included in this plan.
getter/setter pair
- fee ↔ CommerceMoneyResponse
-
getter/setter pair
- forPayerType ↔ String
-
The payer type this plan is designed for.
getter/setter pair
- freeTrialDays ↔ int?
-
Number of free trial days for this plan.
getter/setter pair
- freeTrialEnabled ↔ bool
-
Whether free trial is enabled for this plan.
getter/setter pair
- hasBaseFee ↔ bool
-
Whether this plan has a base fee.
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setteroverride
- id ↔ String
-
Unique identifier for the plan.
getter/setter pair
- isDefault ↔ bool
-
Whether this is the default plan.
getter/setter pair
- isRecurring ↔ bool
-
Whether this is a recurring plan.
getter/setter pair
- name ↔ String
-
The name of the plan.
getter/setter pair
- object ↔ CommercePlanObjectEnum
-
String representing the object's type. Objects of the same type share the same value.
getter/setter pair
- productId ↔ String
-
The ID of the product this plan belongs to.
getter/setter pair
- publiclyVisible ↔ bool
-
Whether this plan is publicly visible.
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- slug ↔ String
-
The URL-friendly slug for the plan.
getter/setter pair
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Static Methods
-
fromJson(
dynamic value) → CommercePlan? -
Returns a new CommercePlan instance and imports its values from
valueif it's a Map, null otherwise. -
listFromJson(
dynamic json, {bool growable = false}) → List< CommercePlan> -
mapFromJson(
dynamic json) → Map< String, CommercePlan> -
mapListFromJson(
dynamic json, {bool growable = false}) → Map< String, List< CommercePlan> >
Constants
-
requiredKeys
→ const Set<
String> - The list of required keys that must be present in a JSON.