copyWith method
FastPlanBlocState
copyWith({
- bool? isPlanPurchasePending,
- bool? hasPurchasedPlan,
- bool? isRestoringPlan,
- String? planId,
- dynamic error,
override
Creates a copy of this TModel but with the given fields replaced with the new values.
For example:
var myModel2 = myModel1.copyWith(age: 42);
Implementation
@override
FastPlanBlocState copyWith({
bool? isPlanPurchasePending,
bool? hasPurchasedPlan,
bool? isRestoringPlan,
String? planId,
dynamic error,
}) {
return FastPlanBlocState(
hasPurchasedPlan: hasPurchasedPlan ?? this.hasPurchasedPlan,
isRestoringPlan: isRestoringPlan ?? this.isRestoringPlan,
planId: planId ?? this.planId,
error: error,
isPlanPurchasePending:
isPlanPurchasePending ?? this.isPlanPurchasePending,
);
}