Sub2ApiUserSubscription class abstract
Current-user subscription and rolling usage windows.
- Available extensions
- Annotations
-
- @freezed
Constructors
- Sub2ApiUserSubscription({required int id, required int userId, required int groupId, required DateTime startsAt, required DateTime expiresAt, required String status, DateTime? dailyWindowStart, DateTime? weeklyWindowStart, DateTime? monthlyWindowStart, required Sub2ApiDecimal dailyUsageUsd, required Sub2ApiDecimal weeklyUsageUsd, required Sub2ApiDecimal monthlyUsageUsd, required DateTime createdAt, required DateTime updatedAt, DateTime? revokedAt, Sub2ApiCommerceGroupSummary? group})
-
constfactory
Properties
-
copyWith
→ $Sub2ApiUserSubscriptionCopyWith<
Sub2ApiUserSubscription> -
Create a copy of Sub2ApiUserSubscription
with the given fields replaced by the non-null parameter values.
no setterinherited
- createdAt → DateTime
-
no setterinherited
- dailyUsageUsd → Sub2ApiDecimal
-
no setterinherited
- dailyWindowStart → DateTime?
-
no setterinherited
- expiresAt → DateTime
-
no setterinherited
- group → Sub2ApiCommerceGroupSummary?
-
no setterinherited
- groupId → int
-
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → int
-
no setterinherited
- monthlyUsageUsd → Sub2ApiDecimal
-
no setterinherited
- monthlyWindowStart → DateTime?
-
no setterinherited
- revokedAt → DateTime?
-
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- startsAt → DateTime
-
no setterinherited
- status → String
-
no setterinherited
- updatedAt → DateTime
-
no setterinherited
- userId → int
-
no setterinherited
- weeklyUsageUsd → Sub2ApiDecimal
-
no setterinherited
- weeklyWindowStart → DateTime?
-
no setterinherited
Methods
-
map<
TResult extends Object?> (TResult $default(_Sub2ApiUserSubscription value)) → TResult -
Available on Sub2ApiUserSubscription, provided by the Sub2ApiUserSubscriptionPatterns extension
Aswitch-like method, using callbacks. -
mapOrNull<
TResult extends Object?> (TResult? $default(_Sub2ApiUserSubscription value)?) → TResult? -
Available on Sub2ApiUserSubscription, provided by the Sub2ApiUserSubscriptionPatterns extension
A variant ofmapthat fallback to returningnull. -
maybeMap<
TResult extends Object?> (TResult $default(_Sub2ApiUserSubscription value)?, {required TResult orElse()}) → TResult -
Available on Sub2ApiUserSubscription, provided by the Sub2ApiUserSubscriptionPatterns extension
A variant ofmapthat fallback to returningorElse. -
maybeWhen<
TResult extends Object?> (TResult $default(int id, int userId, int groupId, DateTime startsAt, DateTime expiresAt, String status, DateTime? dailyWindowStart, DateTime? weeklyWindowStart, DateTime? monthlyWindowStart, Sub2ApiDecimal dailyUsageUsd, Sub2ApiDecimal weeklyUsageUsd, Sub2ApiDecimal monthlyUsageUsd, DateTime createdAt, DateTime updatedAt, DateTime? revokedAt, Sub2ApiCommerceGroupSummary? group)?, {required TResult orElse()}) → TResult -
Available on Sub2ApiUserSubscription, provided by the Sub2ApiUserSubscriptionPatterns extension
A variant ofwhenthat fallback to anorElsecallback. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
when<
TResult extends Object?> (TResult $default(int id, int userId, int groupId, DateTime startsAt, DateTime expiresAt, String status, DateTime? dailyWindowStart, DateTime? weeklyWindowStart, DateTime? monthlyWindowStart, Sub2ApiDecimal dailyUsageUsd, Sub2ApiDecimal weeklyUsageUsd, Sub2ApiDecimal monthlyUsageUsd, DateTime createdAt, DateTime updatedAt, DateTime? revokedAt, Sub2ApiCommerceGroupSummary? group)) → TResult -
Available on Sub2ApiUserSubscription, provided by the Sub2ApiUserSubscriptionPatterns extension
Aswitch-like method, using callbacks. -
whenOrNull<
TResult extends Object?> (TResult? $default(int id, int userId, int groupId, DateTime startsAt, DateTime expiresAt, String status, DateTime? dailyWindowStart, DateTime? weeklyWindowStart, DateTime? monthlyWindowStart, Sub2ApiDecimal dailyUsageUsd, Sub2ApiDecimal weeklyUsageUsd, Sub2ApiDecimal monthlyUsageUsd, DateTime createdAt, DateTime updatedAt, DateTime? revokedAt, Sub2ApiCommerceGroupSummary? group)?) → TResult? -
Available on Sub2ApiUserSubscription, provided by the Sub2ApiUserSubscriptionPatterns extension
A variant ofwhenthat fallback to returningnull
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited