copyWith method

PasswordState copyWith({
  1. bool? hasPassword,
  2. String? passwordHint,
  3. bool? hasRecoveryEmailAddress,
  4. bool? hasPassportData,
  5. EmailAddressAuthenticationCodeInfo? recoveryEmailAddressCodeInfo()?,
  6. String? loginEmailAddressPattern,
  7. int? pendingResetDate,
  8. dynamic extra,
  9. int? clientId,
})

Returns a copy with the given fields replaced. For a nullable field pass a function, e.g. field: () => null to clear it.

Implementation

PasswordState copyWith({
  bool? hasPassword,
  String? passwordHint,
  bool? hasRecoveryEmailAddress,
  bool? hasPassportData,
  EmailAddressAuthenticationCodeInfo? Function()?
  recoveryEmailAddressCodeInfo,
  String? loginEmailAddressPattern,
  int? pendingResetDate,
  dynamic extra,
  int? clientId,
}) => PasswordState(
  hasPassword: hasPassword ?? this.hasPassword,
  passwordHint: passwordHint ?? this.passwordHint,
  hasRecoveryEmailAddress:
      hasRecoveryEmailAddress ?? this.hasRecoveryEmailAddress,
  hasPassportData: hasPassportData ?? this.hasPassportData,
  recoveryEmailAddressCodeInfo: recoveryEmailAddressCodeInfo != null
      ? recoveryEmailAddressCodeInfo()
      : this.recoveryEmailAddressCodeInfo,
  loginEmailAddressPattern:
      loginEmailAddressPattern ?? this.loginEmailAddressPattern,
  pendingResetDate: pendingResetDate ?? this.pendingResetDate,
  extra: extra ?? this.extra,
  clientId: clientId ?? this.clientId,
);