70 lines
2.7 KiB
Dart
70 lines
2.7 KiB
Dart
// GENERATED CODE - DO NOT MODIFY BY HAND
|
|
|
|
part of 'currency_state.dart';
|
|
|
|
// **************************************************************************
|
|
// CopyWithGenerator
|
|
// **************************************************************************
|
|
|
|
abstract class _$CurrencyStateCWProxy {
|
|
CurrencyState currencyId(String? currencyId);
|
|
|
|
CurrencyState hasCurrencyLoaded(bool hasCurrencyLoaded);
|
|
|
|
/// This function **does support** nullification of nullable fields. All `null` values passed to `non-nullable` fields will be ignored. You can also use `CurrencyState(...).copyWith.fieldName(...)` to override fields one at a time with nullification support.
|
|
///
|
|
/// Usage
|
|
/// ```dart
|
|
/// CurrencyState(...).copyWith(id: 12, name: "My name")
|
|
/// ````
|
|
CurrencyState call({
|
|
String? currencyId,
|
|
bool? hasCurrencyLoaded,
|
|
});
|
|
}
|
|
|
|
/// Proxy class for `copyWith` functionality. This is a callable class and can be used as follows: `instanceOfCurrencyState.copyWith(...)`. Additionally contains functions for specific fields e.g. `instanceOfCurrencyState.copyWith.fieldName(...)`
|
|
class _$CurrencyStateCWProxyImpl implements _$CurrencyStateCWProxy {
|
|
const _$CurrencyStateCWProxyImpl(this._value);
|
|
|
|
final CurrencyState _value;
|
|
|
|
@override
|
|
CurrencyState currencyId(String? currencyId) => this(currencyId: currencyId);
|
|
|
|
@override
|
|
CurrencyState hasCurrencyLoaded(bool hasCurrencyLoaded) =>
|
|
this(hasCurrencyLoaded: hasCurrencyLoaded);
|
|
|
|
@override
|
|
|
|
/// This function **does support** nullification of nullable fields. All `null` values passed to `non-nullable` fields will be ignored. You can also use `CurrencyState(...).copyWith.fieldName(...)` to override fields one at a time with nullification support.
|
|
///
|
|
/// Usage
|
|
/// ```dart
|
|
/// CurrencyState(...).copyWith(id: 12, name: "My name")
|
|
/// ````
|
|
CurrencyState call({
|
|
Object? currencyId = const $CopyWithPlaceholder(),
|
|
Object? hasCurrencyLoaded = const $CopyWithPlaceholder(),
|
|
}) {
|
|
return CurrencyState(
|
|
currencyId: currencyId == const $CopyWithPlaceholder()
|
|
? _value.currencyId
|
|
// ignore: cast_nullable_to_non_nullable
|
|
: currencyId as String?,
|
|
hasCurrencyLoaded: hasCurrencyLoaded == const $CopyWithPlaceholder() ||
|
|
hasCurrencyLoaded == null
|
|
? _value.hasCurrencyLoaded
|
|
// ignore: cast_nullable_to_non_nullable
|
|
: hasCurrencyLoaded as bool,
|
|
);
|
|
}
|
|
}
|
|
|
|
extension $CurrencyStateCopyWith on CurrencyState {
|
|
/// Returns a callable class that can be used as follows: `instanceOfCurrencyState.copyWith(...)` or like so:`instanceOfCurrencyState.copyWith.fieldName(...)`.
|
|
// ignore: library_private_types_in_public_api
|
|
_$CurrencyStateCWProxy get copyWith => _$CurrencyStateCWProxyImpl(this);
|
|
}
|