580 lines
17 KiB
Dart
580 lines
17 KiB
Dart
// GENERATED CODE - DO NOT MODIFY BY HAND
|
|
// coverage:ignore-file
|
|
// ignore_for_file: type=lint
|
|
// ignore_for_file: unused_element, deprecated_member_use, deprecated_member_use_from_same_package, use_function_type_syntax_for_parameters, unnecessary_const, avoid_init_to_null, invalid_override_different_default_values_named, prefer_expression_function_bodies, annotate_overrides, invalid_annotation_target, unnecessary_question_mark
|
|
|
|
part of 'app_info_model.dart';
|
|
|
|
// **************************************************************************
|
|
// FreezedGenerator
|
|
// **************************************************************************
|
|
|
|
// dart format off
|
|
T _$identity<T>(T value) => value;
|
|
|
|
/// @nodoc
|
|
mixin _$AppInfoModel {
|
|
|
|
String? get key; String? get file; Info? get info;
|
|
/// Create a copy of AppInfoModel
|
|
/// with the given fields replaced by the non-null parameter values.
|
|
@JsonKey(includeFromJson: false, includeToJson: false)
|
|
@pragma('vm:prefer-inline')
|
|
$AppInfoModelCopyWith<AppInfoModel> get copyWith => _$AppInfoModelCopyWithImpl<AppInfoModel>(this as AppInfoModel, _$identity);
|
|
|
|
/// Serializes this AppInfoModel to a JSON map.
|
|
Map<String, dynamic> toJson();
|
|
|
|
|
|
@override
|
|
bool operator ==(Object other) {
|
|
return identical(this, other) || (other.runtimeType == runtimeType&&other is AppInfoModel&&(identical(other.key, key) || other.key == key)&&(identical(other.file, file) || other.file == file)&&(identical(other.info, info) || other.info == info));
|
|
}
|
|
|
|
@JsonKey(includeFromJson: false, includeToJson: false)
|
|
@override
|
|
int get hashCode => Object.hash(runtimeType,key,file,info);
|
|
|
|
@override
|
|
String toString() {
|
|
return 'AppInfoModel(key: $key, file: $file, info: $info)';
|
|
}
|
|
|
|
|
|
}
|
|
|
|
/// @nodoc
|
|
abstract mixin class $AppInfoModelCopyWith<$Res> {
|
|
factory $AppInfoModelCopyWith(AppInfoModel value, $Res Function(AppInfoModel) _then) = _$AppInfoModelCopyWithImpl;
|
|
@useResult
|
|
$Res call({
|
|
String? key, String? file, Info? info
|
|
});
|
|
|
|
|
|
$InfoCopyWith<$Res>? get info;
|
|
|
|
}
|
|
/// @nodoc
|
|
class _$AppInfoModelCopyWithImpl<$Res>
|
|
implements $AppInfoModelCopyWith<$Res> {
|
|
_$AppInfoModelCopyWithImpl(this._self, this._then);
|
|
|
|
final AppInfoModel _self;
|
|
final $Res Function(AppInfoModel) _then;
|
|
|
|
/// Create a copy of AppInfoModel
|
|
/// with the given fields replaced by the non-null parameter values.
|
|
@pragma('vm:prefer-inline') @override $Res call({Object? key = freezed,Object? file = freezed,Object? info = freezed,}) {
|
|
return _then(_self.copyWith(
|
|
key: freezed == key ? _self.key : key // ignore: cast_nullable_to_non_nullable
|
|
as String?,file: freezed == file ? _self.file : file // ignore: cast_nullable_to_non_nullable
|
|
as String?,info: freezed == info ? _self.info : info // ignore: cast_nullable_to_non_nullable
|
|
as Info?,
|
|
));
|
|
}
|
|
/// Create a copy of AppInfoModel
|
|
/// with the given fields replaced by the non-null parameter values.
|
|
@override
|
|
@pragma('vm:prefer-inline')
|
|
$InfoCopyWith<$Res>? get info {
|
|
if (_self.info == null) {
|
|
return null;
|
|
}
|
|
|
|
return $InfoCopyWith<$Res>(_self.info!, (value) {
|
|
return _then(_self.copyWith(info: value));
|
|
});
|
|
}
|
|
}
|
|
|
|
|
|
/// Adds pattern-matching-related methods to [AppInfoModel].
|
|
extension AppInfoModelPatterns on AppInfoModel {
|
|
/// A variant of `map` that fallback to returning `orElse`.
|
|
///
|
|
/// It is equivalent to doing:
|
|
/// ```dart
|
|
/// switch (sealedClass) {
|
|
/// case final Subclass value:
|
|
/// return ...;
|
|
/// case _:
|
|
/// return orElse();
|
|
/// }
|
|
/// ```
|
|
|
|
@optionalTypeArgs TResult maybeMap<TResult extends Object?>(TResult Function( _AppInfoModel value)? $default,{required TResult orElse(),}){
|
|
final _that = this;
|
|
switch (_that) {
|
|
case _AppInfoModel() when $default != null:
|
|
return $default(_that);case _:
|
|
return orElse();
|
|
|
|
}
|
|
}
|
|
/// A `switch`-like method, using callbacks.
|
|
///
|
|
/// Callbacks receives the raw object, upcasted.
|
|
/// It is equivalent to doing:
|
|
/// ```dart
|
|
/// switch (sealedClass) {
|
|
/// case final Subclass value:
|
|
/// return ...;
|
|
/// case final Subclass2 value:
|
|
/// return ...;
|
|
/// }
|
|
/// ```
|
|
|
|
@optionalTypeArgs TResult map<TResult extends Object?>(TResult Function( _AppInfoModel value) $default,){
|
|
final _that = this;
|
|
switch (_that) {
|
|
case _AppInfoModel():
|
|
return $default(_that);case _:
|
|
throw StateError('Unexpected subclass');
|
|
|
|
}
|
|
}
|
|
/// A variant of `map` that fallback to returning `null`.
|
|
///
|
|
/// It is equivalent to doing:
|
|
/// ```dart
|
|
/// switch (sealedClass) {
|
|
/// case final Subclass value:
|
|
/// return ...;
|
|
/// case _:
|
|
/// return null;
|
|
/// }
|
|
/// ```
|
|
|
|
@optionalTypeArgs TResult? mapOrNull<TResult extends Object?>(TResult? Function( _AppInfoModel value)? $default,){
|
|
final _that = this;
|
|
switch (_that) {
|
|
case _AppInfoModel() when $default != null:
|
|
return $default(_that);case _:
|
|
return null;
|
|
|
|
}
|
|
}
|
|
/// A variant of `when` that fallback to an `orElse` callback.
|
|
///
|
|
/// It is equivalent to doing:
|
|
/// ```dart
|
|
/// switch (sealedClass) {
|
|
/// case Subclass(:final field):
|
|
/// return ...;
|
|
/// case _:
|
|
/// return orElse();
|
|
/// }
|
|
/// ```
|
|
|
|
@optionalTypeArgs TResult maybeWhen<TResult extends Object?>(TResult Function( String? key, String? file, Info? info)? $default,{required TResult orElse(),}) {final _that = this;
|
|
switch (_that) {
|
|
case _AppInfoModel() when $default != null:
|
|
return $default(_that.key,_that.file,_that.info);case _:
|
|
return orElse();
|
|
|
|
}
|
|
}
|
|
/// A `switch`-like method, using callbacks.
|
|
///
|
|
/// As opposed to `map`, this offers destructuring.
|
|
/// It is equivalent to doing:
|
|
/// ```dart
|
|
/// switch (sealedClass) {
|
|
/// case Subclass(:final field):
|
|
/// return ...;
|
|
/// case Subclass2(:final field2):
|
|
/// return ...;
|
|
/// }
|
|
/// ```
|
|
|
|
@optionalTypeArgs TResult when<TResult extends Object?>(TResult Function( String? key, String? file, Info? info) $default,) {final _that = this;
|
|
switch (_that) {
|
|
case _AppInfoModel():
|
|
return $default(_that.key,_that.file,_that.info);case _:
|
|
throw StateError('Unexpected subclass');
|
|
|
|
}
|
|
}
|
|
/// A variant of `when` that fallback to returning `null`
|
|
///
|
|
/// It is equivalent to doing:
|
|
/// ```dart
|
|
/// switch (sealedClass) {
|
|
/// case Subclass(:final field):
|
|
/// return ...;
|
|
/// case _:
|
|
/// return null;
|
|
/// }
|
|
/// ```
|
|
|
|
@optionalTypeArgs TResult? whenOrNull<TResult extends Object?>(TResult? Function( String? key, String? file, Info? info)? $default,) {final _that = this;
|
|
switch (_that) {
|
|
case _AppInfoModel() when $default != null:
|
|
return $default(_that.key,_that.file,_that.info);case _:
|
|
return null;
|
|
|
|
}
|
|
}
|
|
|
|
}
|
|
|
|
/// @nodoc
|
|
@JsonSerializable()
|
|
|
|
class _AppInfoModel implements AppInfoModel {
|
|
const _AppInfoModel({this.key, this.file, this.info});
|
|
factory _AppInfoModel.fromJson(Map<String, dynamic> json) => _$AppInfoModelFromJson(json);
|
|
|
|
@override final String? key;
|
|
@override final String? file;
|
|
@override final Info? info;
|
|
|
|
/// Create a copy of AppInfoModel
|
|
/// with the given fields replaced by the non-null parameter values.
|
|
@override @JsonKey(includeFromJson: false, includeToJson: false)
|
|
@pragma('vm:prefer-inline')
|
|
_$AppInfoModelCopyWith<_AppInfoModel> get copyWith => __$AppInfoModelCopyWithImpl<_AppInfoModel>(this, _$identity);
|
|
|
|
@override
|
|
Map<String, dynamic> toJson() {
|
|
return _$AppInfoModelToJson(this, );
|
|
}
|
|
|
|
@override
|
|
bool operator ==(Object other) {
|
|
return identical(this, other) || (other.runtimeType == runtimeType&&other is _AppInfoModel&&(identical(other.key, key) || other.key == key)&&(identical(other.file, file) || other.file == file)&&(identical(other.info, info) || other.info == info));
|
|
}
|
|
|
|
@JsonKey(includeFromJson: false, includeToJson: false)
|
|
@override
|
|
int get hashCode => Object.hash(runtimeType,key,file,info);
|
|
|
|
@override
|
|
String toString() {
|
|
return 'AppInfoModel(key: $key, file: $file, info: $info)';
|
|
}
|
|
|
|
|
|
}
|
|
|
|
/// @nodoc
|
|
abstract mixin class _$AppInfoModelCopyWith<$Res> implements $AppInfoModelCopyWith<$Res> {
|
|
factory _$AppInfoModelCopyWith(_AppInfoModel value, $Res Function(_AppInfoModel) _then) = __$AppInfoModelCopyWithImpl;
|
|
@override @useResult
|
|
$Res call({
|
|
String? key, String? file, Info? info
|
|
});
|
|
|
|
|
|
@override $InfoCopyWith<$Res>? get info;
|
|
|
|
}
|
|
/// @nodoc
|
|
class __$AppInfoModelCopyWithImpl<$Res>
|
|
implements _$AppInfoModelCopyWith<$Res> {
|
|
__$AppInfoModelCopyWithImpl(this._self, this._then);
|
|
|
|
final _AppInfoModel _self;
|
|
final $Res Function(_AppInfoModel) _then;
|
|
|
|
/// Create a copy of AppInfoModel
|
|
/// with the given fields replaced by the non-null parameter values.
|
|
@override @pragma('vm:prefer-inline') $Res call({Object? key = freezed,Object? file = freezed,Object? info = freezed,}) {
|
|
return _then(_AppInfoModel(
|
|
key: freezed == key ? _self.key : key // ignore: cast_nullable_to_non_nullable
|
|
as String?,file: freezed == file ? _self.file : file // ignore: cast_nullable_to_non_nullable
|
|
as String?,info: freezed == info ? _self.info : info // ignore: cast_nullable_to_non_nullable
|
|
as Info?,
|
|
));
|
|
}
|
|
|
|
/// Create a copy of AppInfoModel
|
|
/// with the given fields replaced by the non-null parameter values.
|
|
@override
|
|
@pragma('vm:prefer-inline')
|
|
$InfoCopyWith<$Res>? get info {
|
|
if (_self.info == null) {
|
|
return null;
|
|
}
|
|
|
|
return $InfoCopyWith<$Res>(_self.info!, (value) {
|
|
return _then(_self.copyWith(info: value));
|
|
});
|
|
}
|
|
}
|
|
|
|
|
|
/// @nodoc
|
|
mixin _$Info {
|
|
|
|
String? get version; String? get minVersion; String? get module; bool? get required;
|
|
/// Create a copy of Info
|
|
/// with the given fields replaced by the non-null parameter values.
|
|
@JsonKey(includeFromJson: false, includeToJson: false)
|
|
@pragma('vm:prefer-inline')
|
|
$InfoCopyWith<Info> get copyWith => _$InfoCopyWithImpl<Info>(this as Info, _$identity);
|
|
|
|
/// Serializes this Info to a JSON map.
|
|
Map<String, dynamic> toJson();
|
|
|
|
|
|
@override
|
|
bool operator ==(Object other) {
|
|
return identical(this, other) || (other.runtimeType == runtimeType&&other is Info&&(identical(other.version, version) || other.version == version)&&(identical(other.minVersion, minVersion) || other.minVersion == minVersion)&&(identical(other.module, module) || other.module == module)&&(identical(other.required, required) || other.required == required));
|
|
}
|
|
|
|
@JsonKey(includeFromJson: false, includeToJson: false)
|
|
@override
|
|
int get hashCode => Object.hash(runtimeType,version,minVersion,module,required);
|
|
|
|
@override
|
|
String toString() {
|
|
return 'Info(version: $version, minVersion: $minVersion, module: $module, required: $required)';
|
|
}
|
|
|
|
|
|
}
|
|
|
|
/// @nodoc
|
|
abstract mixin class $InfoCopyWith<$Res> {
|
|
factory $InfoCopyWith(Info value, $Res Function(Info) _then) = _$InfoCopyWithImpl;
|
|
@useResult
|
|
$Res call({
|
|
String? version, String? minVersion, String? module, bool? required
|
|
});
|
|
|
|
|
|
|
|
|
|
}
|
|
/// @nodoc
|
|
class _$InfoCopyWithImpl<$Res>
|
|
implements $InfoCopyWith<$Res> {
|
|
_$InfoCopyWithImpl(this._self, this._then);
|
|
|
|
final Info _self;
|
|
final $Res Function(Info) _then;
|
|
|
|
/// Create a copy of Info
|
|
/// with the given fields replaced by the non-null parameter values.
|
|
@pragma('vm:prefer-inline') @override $Res call({Object? version = freezed,Object? minVersion = freezed,Object? module = freezed,Object? required = freezed,}) {
|
|
return _then(_self.copyWith(
|
|
version: freezed == version ? _self.version : version // ignore: cast_nullable_to_non_nullable
|
|
as String?,minVersion: freezed == minVersion ? _self.minVersion : minVersion // ignore: cast_nullable_to_non_nullable
|
|
as String?,module: freezed == module ? _self.module : module // ignore: cast_nullable_to_non_nullable
|
|
as String?,required: freezed == required ? _self.required : required // ignore: cast_nullable_to_non_nullable
|
|
as bool?,
|
|
));
|
|
}
|
|
|
|
}
|
|
|
|
|
|
/// Adds pattern-matching-related methods to [Info].
|
|
extension InfoPatterns on Info {
|
|
/// A variant of `map` that fallback to returning `orElse`.
|
|
///
|
|
/// It is equivalent to doing:
|
|
/// ```dart
|
|
/// switch (sealedClass) {
|
|
/// case final Subclass value:
|
|
/// return ...;
|
|
/// case _:
|
|
/// return orElse();
|
|
/// }
|
|
/// ```
|
|
|
|
@optionalTypeArgs TResult maybeMap<TResult extends Object?>(TResult Function( _Info value)? $default,{required TResult orElse(),}){
|
|
final _that = this;
|
|
switch (_that) {
|
|
case _Info() when $default != null:
|
|
return $default(_that);case _:
|
|
return orElse();
|
|
|
|
}
|
|
}
|
|
/// A `switch`-like method, using callbacks.
|
|
///
|
|
/// Callbacks receives the raw object, upcasted.
|
|
/// It is equivalent to doing:
|
|
/// ```dart
|
|
/// switch (sealedClass) {
|
|
/// case final Subclass value:
|
|
/// return ...;
|
|
/// case final Subclass2 value:
|
|
/// return ...;
|
|
/// }
|
|
/// ```
|
|
|
|
@optionalTypeArgs TResult map<TResult extends Object?>(TResult Function( _Info value) $default,){
|
|
final _that = this;
|
|
switch (_that) {
|
|
case _Info():
|
|
return $default(_that);case _:
|
|
throw StateError('Unexpected subclass');
|
|
|
|
}
|
|
}
|
|
/// A variant of `map` that fallback to returning `null`.
|
|
///
|
|
/// It is equivalent to doing:
|
|
/// ```dart
|
|
/// switch (sealedClass) {
|
|
/// case final Subclass value:
|
|
/// return ...;
|
|
/// case _:
|
|
/// return null;
|
|
/// }
|
|
/// ```
|
|
|
|
@optionalTypeArgs TResult? mapOrNull<TResult extends Object?>(TResult? Function( _Info value)? $default,){
|
|
final _that = this;
|
|
switch (_that) {
|
|
case _Info() when $default != null:
|
|
return $default(_that);case _:
|
|
return null;
|
|
|
|
}
|
|
}
|
|
/// A variant of `when` that fallback to an `orElse` callback.
|
|
///
|
|
/// It is equivalent to doing:
|
|
/// ```dart
|
|
/// switch (sealedClass) {
|
|
/// case Subclass(:final field):
|
|
/// return ...;
|
|
/// case _:
|
|
/// return orElse();
|
|
/// }
|
|
/// ```
|
|
|
|
@optionalTypeArgs TResult maybeWhen<TResult extends Object?>(TResult Function( String? version, String? minVersion, String? module, bool? required)? $default,{required TResult orElse(),}) {final _that = this;
|
|
switch (_that) {
|
|
case _Info() when $default != null:
|
|
return $default(_that.version,_that.minVersion,_that.module,_that.required);case _:
|
|
return orElse();
|
|
|
|
}
|
|
}
|
|
/// A `switch`-like method, using callbacks.
|
|
///
|
|
/// As opposed to `map`, this offers destructuring.
|
|
/// It is equivalent to doing:
|
|
/// ```dart
|
|
/// switch (sealedClass) {
|
|
/// case Subclass(:final field):
|
|
/// return ...;
|
|
/// case Subclass2(:final field2):
|
|
/// return ...;
|
|
/// }
|
|
/// ```
|
|
|
|
@optionalTypeArgs TResult when<TResult extends Object?>(TResult Function( String? version, String? minVersion, String? module, bool? required) $default,) {final _that = this;
|
|
switch (_that) {
|
|
case _Info():
|
|
return $default(_that.version,_that.minVersion,_that.module,_that.required);case _:
|
|
throw StateError('Unexpected subclass');
|
|
|
|
}
|
|
}
|
|
/// A variant of `when` that fallback to returning `null`
|
|
///
|
|
/// It is equivalent to doing:
|
|
/// ```dart
|
|
/// switch (sealedClass) {
|
|
/// case Subclass(:final field):
|
|
/// return ...;
|
|
/// case _:
|
|
/// return null;
|
|
/// }
|
|
/// ```
|
|
|
|
@optionalTypeArgs TResult? whenOrNull<TResult extends Object?>(TResult? Function( String? version, String? minVersion, String? module, bool? required)? $default,) {final _that = this;
|
|
switch (_that) {
|
|
case _Info() when $default != null:
|
|
return $default(_that.version,_that.minVersion,_that.module,_that.required);case _:
|
|
return null;
|
|
|
|
}
|
|
}
|
|
|
|
}
|
|
|
|
/// @nodoc
|
|
@JsonSerializable()
|
|
|
|
class _Info implements Info {
|
|
const _Info({this.version, this.minVersion, this.module, this.required});
|
|
factory _Info.fromJson(Map<String, dynamic> json) => _$InfoFromJson(json);
|
|
|
|
@override final String? version;
|
|
@override final String? minVersion;
|
|
@override final String? module;
|
|
@override final bool? required;
|
|
|
|
/// Create a copy of Info
|
|
/// with the given fields replaced by the non-null parameter values.
|
|
@override @JsonKey(includeFromJson: false, includeToJson: false)
|
|
@pragma('vm:prefer-inline')
|
|
_$InfoCopyWith<_Info> get copyWith => __$InfoCopyWithImpl<_Info>(this, _$identity);
|
|
|
|
@override
|
|
Map<String, dynamic> toJson() {
|
|
return _$InfoToJson(this, );
|
|
}
|
|
|
|
@override
|
|
bool operator ==(Object other) {
|
|
return identical(this, other) || (other.runtimeType == runtimeType&&other is _Info&&(identical(other.version, version) || other.version == version)&&(identical(other.minVersion, minVersion) || other.minVersion == minVersion)&&(identical(other.module, module) || other.module == module)&&(identical(other.required, required) || other.required == required));
|
|
}
|
|
|
|
@JsonKey(includeFromJson: false, includeToJson: false)
|
|
@override
|
|
int get hashCode => Object.hash(runtimeType,version,minVersion,module,required);
|
|
|
|
@override
|
|
String toString() {
|
|
return 'Info(version: $version, minVersion: $minVersion, module: $module, required: $required)';
|
|
}
|
|
|
|
|
|
}
|
|
|
|
/// @nodoc
|
|
abstract mixin class _$InfoCopyWith<$Res> implements $InfoCopyWith<$Res> {
|
|
factory _$InfoCopyWith(_Info value, $Res Function(_Info) _then) = __$InfoCopyWithImpl;
|
|
@override @useResult
|
|
$Res call({
|
|
String? version, String? minVersion, String? module, bool? required
|
|
});
|
|
|
|
|
|
|
|
|
|
}
|
|
/// @nodoc
|
|
class __$InfoCopyWithImpl<$Res>
|
|
implements _$InfoCopyWith<$Res> {
|
|
__$InfoCopyWithImpl(this._self, this._then);
|
|
|
|
final _Info _self;
|
|
final $Res Function(_Info) _then;
|
|
|
|
/// Create a copy of Info
|
|
/// with the given fields replaced by the non-null parameter values.
|
|
@override @pragma('vm:prefer-inline') $Res call({Object? version = freezed,Object? minVersion = freezed,Object? module = freezed,Object? required = freezed,}) {
|
|
return _then(_Info(
|
|
version: freezed == version ? _self.version : version // ignore: cast_nullable_to_non_nullable
|
|
as String?,minVersion: freezed == minVersion ? _self.minVersion : minVersion // ignore: cast_nullable_to_non_nullable
|
|
as String?,module: freezed == module ? _self.module : module // ignore: cast_nullable_to_non_nullable
|
|
as String?,required: freezed == required ? _self.required : required // ignore: cast_nullable_to_non_nullable
|
|
as bool?,
|
|
));
|
|
}
|
|
|
|
|
|
}
|
|
|
|
// dart format on
|