chore(app): сгенерированный Dart-клиент с методами аналитики
just gen-client после новых роутов.
This commit is contained in:
@@ -0,0 +1,320 @@
|
||||
// GENERATED CODE - DO NOT MODIFY BY HAND
|
||||
|
||||
part of 'instrument_out.dart';
|
||||
|
||||
// **************************************************************************
|
||||
// CopyWithGenerator
|
||||
// **************************************************************************
|
||||
|
||||
abstract class _$InstrumentOutCWProxy {
|
||||
InstrumentOut assetClass(String assetClass);
|
||||
|
||||
InstrumentOut board(String? board);
|
||||
|
||||
InstrumentOut country(String? country);
|
||||
|
||||
InstrumentOut currency(String currency);
|
||||
|
||||
InstrumentOut exchange(String? exchange);
|
||||
|
||||
InstrumentOut figi(String? figi);
|
||||
|
||||
InstrumentOut id(int id);
|
||||
|
||||
InstrumentOut isActive(bool isActive);
|
||||
|
||||
InstrumentOut isin(String? isin);
|
||||
|
||||
InstrumentOut issuer(String? issuer);
|
||||
|
||||
InstrumentOut lot(int lot);
|
||||
|
||||
InstrumentOut maturityDate(DateTime? maturityDate);
|
||||
|
||||
InstrumentOut name(String name);
|
||||
|
||||
InstrumentOut nominal(String? nominal);
|
||||
|
||||
InstrumentOut nominalCurrency(String? nominalCurrency);
|
||||
|
||||
InstrumentOut sector(String? sector);
|
||||
|
||||
InstrumentOut ticker(String? ticker);
|
||||
|
||||
/// This function **does support** nullification of nullable fields. All `null` values passed to `non-nullable` fields will be ignored. You can also use `InstrumentOut(...).copyWith.fieldName(...)` to override fields one at a time with nullification support.
|
||||
///
|
||||
/// Usage
|
||||
/// ```dart
|
||||
/// InstrumentOut(...).copyWith(id: 12, name: "My name")
|
||||
/// ````
|
||||
InstrumentOut call({
|
||||
String assetClass,
|
||||
String? board,
|
||||
String? country,
|
||||
String currency,
|
||||
String? exchange,
|
||||
String? figi,
|
||||
int id,
|
||||
bool isActive,
|
||||
String? isin,
|
||||
String? issuer,
|
||||
int lot,
|
||||
DateTime? maturityDate,
|
||||
String name,
|
||||
String? nominal,
|
||||
String? nominalCurrency,
|
||||
String? sector,
|
||||
String? ticker,
|
||||
});
|
||||
}
|
||||
|
||||
/// Proxy class for `copyWith` functionality. This is a callable class and can be used as follows: `instanceOfInstrumentOut.copyWith(...)`. Additionally contains functions for specific fields e.g. `instanceOfInstrumentOut.copyWith.fieldName(...)`
|
||||
class _$InstrumentOutCWProxyImpl implements _$InstrumentOutCWProxy {
|
||||
const _$InstrumentOutCWProxyImpl(this._value);
|
||||
|
||||
final InstrumentOut _value;
|
||||
|
||||
@override
|
||||
InstrumentOut assetClass(String assetClass) => this(assetClass: assetClass);
|
||||
|
||||
@override
|
||||
InstrumentOut board(String? board) => this(board: board);
|
||||
|
||||
@override
|
||||
InstrumentOut country(String? country) => this(country: country);
|
||||
|
||||
@override
|
||||
InstrumentOut currency(String currency) => this(currency: currency);
|
||||
|
||||
@override
|
||||
InstrumentOut exchange(String? exchange) => this(exchange: exchange);
|
||||
|
||||
@override
|
||||
InstrumentOut figi(String? figi) => this(figi: figi);
|
||||
|
||||
@override
|
||||
InstrumentOut id(int id) => this(id: id);
|
||||
|
||||
@override
|
||||
InstrumentOut isActive(bool isActive) => this(isActive: isActive);
|
||||
|
||||
@override
|
||||
InstrumentOut isin(String? isin) => this(isin: isin);
|
||||
|
||||
@override
|
||||
InstrumentOut issuer(String? issuer) => this(issuer: issuer);
|
||||
|
||||
@override
|
||||
InstrumentOut lot(int lot) => this(lot: lot);
|
||||
|
||||
@override
|
||||
InstrumentOut maturityDate(DateTime? maturityDate) =>
|
||||
this(maturityDate: maturityDate);
|
||||
|
||||
@override
|
||||
InstrumentOut name(String name) => this(name: name);
|
||||
|
||||
@override
|
||||
InstrumentOut nominal(String? nominal) => this(nominal: nominal);
|
||||
|
||||
@override
|
||||
InstrumentOut nominalCurrency(String? nominalCurrency) =>
|
||||
this(nominalCurrency: nominalCurrency);
|
||||
|
||||
@override
|
||||
InstrumentOut sector(String? sector) => this(sector: sector);
|
||||
|
||||
@override
|
||||
InstrumentOut ticker(String? ticker) => this(ticker: ticker);
|
||||
|
||||
@override
|
||||
/// This function **does support** nullification of nullable fields. All `null` values passed to `non-nullable` fields will be ignored. You can also use `InstrumentOut(...).copyWith.fieldName(...)` to override fields one at a time with nullification support.
|
||||
///
|
||||
/// Usage
|
||||
/// ```dart
|
||||
/// InstrumentOut(...).copyWith(id: 12, name: "My name")
|
||||
/// ````
|
||||
InstrumentOut call({
|
||||
Object? assetClass = const $CopyWithPlaceholder(),
|
||||
Object? board = const $CopyWithPlaceholder(),
|
||||
Object? country = const $CopyWithPlaceholder(),
|
||||
Object? currency = const $CopyWithPlaceholder(),
|
||||
Object? exchange = const $CopyWithPlaceholder(),
|
||||
Object? figi = const $CopyWithPlaceholder(),
|
||||
Object? id = const $CopyWithPlaceholder(),
|
||||
Object? isActive = const $CopyWithPlaceholder(),
|
||||
Object? isin = const $CopyWithPlaceholder(),
|
||||
Object? issuer = const $CopyWithPlaceholder(),
|
||||
Object? lot = const $CopyWithPlaceholder(),
|
||||
Object? maturityDate = const $CopyWithPlaceholder(),
|
||||
Object? name = const $CopyWithPlaceholder(),
|
||||
Object? nominal = const $CopyWithPlaceholder(),
|
||||
Object? nominalCurrency = const $CopyWithPlaceholder(),
|
||||
Object? sector = const $CopyWithPlaceholder(),
|
||||
Object? ticker = const $CopyWithPlaceholder(),
|
||||
}) {
|
||||
return InstrumentOut(
|
||||
assetClass: assetClass == const $CopyWithPlaceholder()
|
||||
? _value.assetClass
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: assetClass as String,
|
||||
board: board == const $CopyWithPlaceholder()
|
||||
? _value.board
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: board as String?,
|
||||
country: country == const $CopyWithPlaceholder()
|
||||
? _value.country
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: country as String?,
|
||||
currency: currency == const $CopyWithPlaceholder()
|
||||
? _value.currency
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: currency as String,
|
||||
exchange: exchange == const $CopyWithPlaceholder()
|
||||
? _value.exchange
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: exchange as String?,
|
||||
figi: figi == const $CopyWithPlaceholder()
|
||||
? _value.figi
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: figi as String?,
|
||||
id: id == const $CopyWithPlaceholder()
|
||||
? _value.id
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: id as int,
|
||||
isActive: isActive == const $CopyWithPlaceholder()
|
||||
? _value.isActive
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: isActive as bool,
|
||||
isin: isin == const $CopyWithPlaceholder()
|
||||
? _value.isin
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: isin as String?,
|
||||
issuer: issuer == const $CopyWithPlaceholder()
|
||||
? _value.issuer
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: issuer as String?,
|
||||
lot: lot == const $CopyWithPlaceholder()
|
||||
? _value.lot
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: lot as int,
|
||||
maturityDate: maturityDate == const $CopyWithPlaceholder()
|
||||
? _value.maturityDate
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: maturityDate as DateTime?,
|
||||
name: name == const $CopyWithPlaceholder()
|
||||
? _value.name
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: name as String,
|
||||
nominal: nominal == const $CopyWithPlaceholder()
|
||||
? _value.nominal
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: nominal as String?,
|
||||
nominalCurrency: nominalCurrency == const $CopyWithPlaceholder()
|
||||
? _value.nominalCurrency
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: nominalCurrency as String?,
|
||||
sector: sector == const $CopyWithPlaceholder()
|
||||
? _value.sector
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: sector as String?,
|
||||
ticker: ticker == const $CopyWithPlaceholder()
|
||||
? _value.ticker
|
||||
// ignore: cast_nullable_to_non_nullable
|
||||
: ticker as String?,
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
extension $InstrumentOutCopyWith on InstrumentOut {
|
||||
/// Returns a callable class that can be used as follows: `instanceOfInstrumentOut.copyWith(...)` or like so:`instanceOfInstrumentOut.copyWith.fieldName(...)`.
|
||||
// ignore: library_private_types_in_public_api
|
||||
_$InstrumentOutCWProxy get copyWith => _$InstrumentOutCWProxyImpl(this);
|
||||
}
|
||||
|
||||
// **************************************************************************
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
InstrumentOut _$InstrumentOutFromJson(Map<String, dynamic> json) =>
|
||||
$checkedCreate(
|
||||
'InstrumentOut',
|
||||
json,
|
||||
($checkedConvert) {
|
||||
$checkKeys(
|
||||
json,
|
||||
requiredKeys: const [
|
||||
'asset_class',
|
||||
'board',
|
||||
'country',
|
||||
'currency',
|
||||
'exchange',
|
||||
'figi',
|
||||
'id',
|
||||
'is_active',
|
||||
'isin',
|
||||
'issuer',
|
||||
'lot',
|
||||
'maturity_date',
|
||||
'name',
|
||||
'nominal',
|
||||
'nominal_currency',
|
||||
'sector',
|
||||
'ticker',
|
||||
],
|
||||
);
|
||||
final val = InstrumentOut(
|
||||
assetClass: $checkedConvert('asset_class', (v) => v as String),
|
||||
board: $checkedConvert('board', (v) => v as String?),
|
||||
country: $checkedConvert('country', (v) => v as String?),
|
||||
currency: $checkedConvert('currency', (v) => v as String),
|
||||
exchange: $checkedConvert('exchange', (v) => v as String?),
|
||||
figi: $checkedConvert('figi', (v) => v as String?),
|
||||
id: $checkedConvert('id', (v) => (v as num).toInt()),
|
||||
isActive: $checkedConvert('is_active', (v) => v as bool),
|
||||
isin: $checkedConvert('isin', (v) => v as String?),
|
||||
issuer: $checkedConvert('issuer', (v) => v as String?),
|
||||
lot: $checkedConvert('lot', (v) => (v as num).toInt()),
|
||||
maturityDate: $checkedConvert(
|
||||
'maturity_date',
|
||||
(v) => v == null ? null : DateTime.parse(v as String),
|
||||
),
|
||||
name: $checkedConvert('name', (v) => v as String),
|
||||
nominal: $checkedConvert('nominal', (v) => v as String?),
|
||||
nominalCurrency: $checkedConvert(
|
||||
'nominal_currency',
|
||||
(v) => v as String?,
|
||||
),
|
||||
sector: $checkedConvert('sector', (v) => v as String?),
|
||||
ticker: $checkedConvert('ticker', (v) => v as String?),
|
||||
);
|
||||
return val;
|
||||
},
|
||||
fieldKeyMap: const {
|
||||
'assetClass': 'asset_class',
|
||||
'isActive': 'is_active',
|
||||
'maturityDate': 'maturity_date',
|
||||
'nominalCurrency': 'nominal_currency',
|
||||
},
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$InstrumentOutToJson(InstrumentOut instance) =>
|
||||
<String, dynamic>{
|
||||
'asset_class': instance.assetClass,
|
||||
'board': instance.board,
|
||||
'country': instance.country,
|
||||
'currency': instance.currency,
|
||||
'exchange': instance.exchange,
|
||||
'figi': instance.figi,
|
||||
'id': instance.id,
|
||||
'is_active': instance.isActive,
|
||||
'isin': instance.isin,
|
||||
'issuer': instance.issuer,
|
||||
'lot': instance.lot,
|
||||
'maturity_date': instance.maturityDate?.toIso8601String(),
|
||||
'name': instance.name,
|
||||
'nominal': instance.nominal,
|
||||
'nominal_currency': instance.nominalCurrency,
|
||||
'sector': instance.sector,
|
||||
'ticker': instance.ticker,
|
||||
};
|
||||
Reference in New Issue
Block a user