ranks.freezed.dart 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203
  1. // coverage:ignore-file
  2. // GENERATED CODE - DO NOT MODIFY BY HAND
  3. // ignore_for_file: type=lint
  4. // 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
  5. part of 'ranks.dart';
  6. // **************************************************************************
  7. // FreezedGenerator
  8. // **************************************************************************
  9. T _$identity<T>(T value) => value;
  10. final _privateConstructorUsedError = UnsupportedError(
  11. 'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#adding-getters-and-methods-to-our-models');
  12. Ranks _$RanksFromJson(Map<String, dynamic> json) {
  13. return _Ranks.fromJson(json);
  14. }
  15. /// @nodoc
  16. mixin _$Ranks {
  17. int? get id => throw _privateConstructorUsedError;
  18. String? get name => throw _privateConstructorUsedError;
  19. String? get icon => throw _privateConstructorUsedError;
  20. /// Serializes this Ranks to a JSON map.
  21. Map<String, dynamic> toJson() => throw _privateConstructorUsedError;
  22. /// Create a copy of Ranks
  23. /// with the given fields replaced by the non-null parameter values.
  24. @JsonKey(includeFromJson: false, includeToJson: false)
  25. $RanksCopyWith<Ranks> get copyWith => throw _privateConstructorUsedError;
  26. }
  27. /// @nodoc
  28. abstract class $RanksCopyWith<$Res> {
  29. factory $RanksCopyWith(Ranks value, $Res Function(Ranks) then) =
  30. _$RanksCopyWithImpl<$Res, Ranks>;
  31. @useResult
  32. $Res call({int? id, String? name, String? icon});
  33. }
  34. /// @nodoc
  35. class _$RanksCopyWithImpl<$Res, $Val extends Ranks>
  36. implements $RanksCopyWith<$Res> {
  37. _$RanksCopyWithImpl(this._value, this._then);
  38. // ignore: unused_field
  39. final $Val _value;
  40. // ignore: unused_field
  41. final $Res Function($Val) _then;
  42. /// Create a copy of Ranks
  43. /// with the given fields replaced by the non-null parameter values.
  44. @pragma('vm:prefer-inline')
  45. @override
  46. $Res call({
  47. Object? id = freezed,
  48. Object? name = freezed,
  49. Object? icon = freezed,
  50. }) {
  51. return _then(_value.copyWith(
  52. id: freezed == id
  53. ? _value.id
  54. : id // ignore: cast_nullable_to_non_nullable
  55. as int?,
  56. name: freezed == name
  57. ? _value.name
  58. : name // ignore: cast_nullable_to_non_nullable
  59. as String?,
  60. icon: freezed == icon
  61. ? _value.icon
  62. : icon // ignore: cast_nullable_to_non_nullable
  63. as String?,
  64. ) as $Val);
  65. }
  66. }
  67. /// @nodoc
  68. abstract class _$$RanksImplCopyWith<$Res> implements $RanksCopyWith<$Res> {
  69. factory _$$RanksImplCopyWith(
  70. _$RanksImpl value, $Res Function(_$RanksImpl) then) =
  71. __$$RanksImplCopyWithImpl<$Res>;
  72. @override
  73. @useResult
  74. $Res call({int? id, String? name, String? icon});
  75. }
  76. /// @nodoc
  77. class __$$RanksImplCopyWithImpl<$Res>
  78. extends _$RanksCopyWithImpl<$Res, _$RanksImpl>
  79. implements _$$RanksImplCopyWith<$Res> {
  80. __$$RanksImplCopyWithImpl(
  81. _$RanksImpl _value, $Res Function(_$RanksImpl) _then)
  82. : super(_value, _then);
  83. /// Create a copy of Ranks
  84. /// with the given fields replaced by the non-null parameter values.
  85. @pragma('vm:prefer-inline')
  86. @override
  87. $Res call({
  88. Object? id = freezed,
  89. Object? name = freezed,
  90. Object? icon = freezed,
  91. }) {
  92. return _then(_$RanksImpl(
  93. id: freezed == id
  94. ? _value.id
  95. : id // ignore: cast_nullable_to_non_nullable
  96. as int?,
  97. name: freezed == name
  98. ? _value.name
  99. : name // ignore: cast_nullable_to_non_nullable
  100. as String?,
  101. icon: freezed == icon
  102. ? _value.icon
  103. : icon // ignore: cast_nullable_to_non_nullable
  104. as String?,
  105. ));
  106. }
  107. }
  108. /// @nodoc
  109. @JsonSerializable()
  110. class _$RanksImpl with DiagnosticableTreeMixin implements _Ranks {
  111. const _$RanksImpl({this.id, this.name, this.icon});
  112. factory _$RanksImpl.fromJson(Map<String, dynamic> json) =>
  113. _$$RanksImplFromJson(json);
  114. @override
  115. final int? id;
  116. @override
  117. final String? name;
  118. @override
  119. final String? icon;
  120. @override
  121. String toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) {
  122. return 'Ranks(id: $id, name: $name, icon: $icon)';
  123. }
  124. @override
  125. void debugFillProperties(DiagnosticPropertiesBuilder properties) {
  126. super.debugFillProperties(properties);
  127. properties
  128. ..add(DiagnosticsProperty('type', 'Ranks'))
  129. ..add(DiagnosticsProperty('id', id))
  130. ..add(DiagnosticsProperty('name', name))
  131. ..add(DiagnosticsProperty('icon', icon));
  132. }
  133. @override
  134. bool operator ==(Object other) {
  135. return identical(this, other) ||
  136. (other.runtimeType == runtimeType &&
  137. other is _$RanksImpl &&
  138. (identical(other.id, id) || other.id == id) &&
  139. (identical(other.name, name) || other.name == name) &&
  140. (identical(other.icon, icon) || other.icon == icon));
  141. }
  142. @JsonKey(includeFromJson: false, includeToJson: false)
  143. @override
  144. int get hashCode => Object.hash(runtimeType, id, name, icon);
  145. /// Create a copy of Ranks
  146. /// with the given fields replaced by the non-null parameter values.
  147. @JsonKey(includeFromJson: false, includeToJson: false)
  148. @override
  149. @pragma('vm:prefer-inline')
  150. _$$RanksImplCopyWith<_$RanksImpl> get copyWith =>
  151. __$$RanksImplCopyWithImpl<_$RanksImpl>(this, _$identity);
  152. @override
  153. Map<String, dynamic> toJson() {
  154. return _$$RanksImplToJson(
  155. this,
  156. );
  157. }
  158. }
  159. abstract class _Ranks implements Ranks {
  160. const factory _Ranks(
  161. {final int? id, final String? name, final String? icon}) = _$RanksImpl;
  162. factory _Ranks.fromJson(Map<String, dynamic> json) = _$RanksImpl.fromJson;
  163. @override
  164. int? get id;
  165. @override
  166. String? get name;
  167. @override
  168. String? get icon;
  169. /// Create a copy of Ranks
  170. /// with the given fields replaced by the non-null parameter values.
  171. @override
  172. @JsonKey(includeFromJson: false, includeToJson: false)
  173. _$$RanksImplCopyWith<_$RanksImpl> get copyWith =>
  174. throw _privateConstructorUsedError;
  175. }