sync_response_dto.freezed.dart 9.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278
  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 'sync_response_dto.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. SyncResponseDto _$SyncResponseDtoFromJson(Map<String, dynamic> json) {
  13. return _SyncResponseDto.fromJson(json);
  14. }
  15. /// @nodoc
  16. mixin _$SyncResponseDto {
  17. int get status => throw _privateConstructorUsedError;
  18. String get statusText => throw _privateConstructorUsedError;
  19. int? get idAssegnato => throw _privateConstructorUsedError;
  20. List<String> get messages => throw _privateConstructorUsedError;
  21. List<String> get validationErrors => throw _privateConstructorUsedError;
  22. /// Serializes this SyncResponseDto to a JSON map.
  23. Map<String, dynamic> toJson() => throw _privateConstructorUsedError;
  24. /// Create a copy of SyncResponseDto
  25. /// with the given fields replaced by the non-null parameter values.
  26. @JsonKey(includeFromJson: false, includeToJson: false)
  27. $SyncResponseDtoCopyWith<SyncResponseDto> get copyWith =>
  28. throw _privateConstructorUsedError;
  29. }
  30. /// @nodoc
  31. abstract class $SyncResponseDtoCopyWith<$Res> {
  32. factory $SyncResponseDtoCopyWith(
  33. SyncResponseDto value, $Res Function(SyncResponseDto) then) =
  34. _$SyncResponseDtoCopyWithImpl<$Res, SyncResponseDto>;
  35. @useResult
  36. $Res call(
  37. {int status,
  38. String statusText,
  39. int? idAssegnato,
  40. List<String> messages,
  41. List<String> validationErrors});
  42. }
  43. /// @nodoc
  44. class _$SyncResponseDtoCopyWithImpl<$Res, $Val extends SyncResponseDto>
  45. implements $SyncResponseDtoCopyWith<$Res> {
  46. _$SyncResponseDtoCopyWithImpl(this._value, this._then);
  47. // ignore: unused_field
  48. final $Val _value;
  49. // ignore: unused_field
  50. final $Res Function($Val) _then;
  51. /// Create a copy of SyncResponseDto
  52. /// with the given fields replaced by the non-null parameter values.
  53. @pragma('vm:prefer-inline')
  54. @override
  55. $Res call({
  56. Object? status = null,
  57. Object? statusText = null,
  58. Object? idAssegnato = freezed,
  59. Object? messages = null,
  60. Object? validationErrors = null,
  61. }) {
  62. return _then(_value.copyWith(
  63. status: null == status
  64. ? _value.status
  65. : status // ignore: cast_nullable_to_non_nullable
  66. as int,
  67. statusText: null == statusText
  68. ? _value.statusText
  69. : statusText // ignore: cast_nullable_to_non_nullable
  70. as String,
  71. idAssegnato: freezed == idAssegnato
  72. ? _value.idAssegnato
  73. : idAssegnato // ignore: cast_nullable_to_non_nullable
  74. as int?,
  75. messages: null == messages
  76. ? _value.messages
  77. : messages // ignore: cast_nullable_to_non_nullable
  78. as List<String>,
  79. validationErrors: null == validationErrors
  80. ? _value.validationErrors
  81. : validationErrors // ignore: cast_nullable_to_non_nullable
  82. as List<String>,
  83. ) as $Val);
  84. }
  85. }
  86. /// @nodoc
  87. abstract class _$$SyncResponseDtoImplCopyWith<$Res>
  88. implements $SyncResponseDtoCopyWith<$Res> {
  89. factory _$$SyncResponseDtoImplCopyWith(_$SyncResponseDtoImpl value,
  90. $Res Function(_$SyncResponseDtoImpl) then) =
  91. __$$SyncResponseDtoImplCopyWithImpl<$Res>;
  92. @override
  93. @useResult
  94. $Res call(
  95. {int status,
  96. String statusText,
  97. int? idAssegnato,
  98. List<String> messages,
  99. List<String> validationErrors});
  100. }
  101. /// @nodoc
  102. class __$$SyncResponseDtoImplCopyWithImpl<$Res>
  103. extends _$SyncResponseDtoCopyWithImpl<$Res, _$SyncResponseDtoImpl>
  104. implements _$$SyncResponseDtoImplCopyWith<$Res> {
  105. __$$SyncResponseDtoImplCopyWithImpl(
  106. _$SyncResponseDtoImpl _value, $Res Function(_$SyncResponseDtoImpl) _then)
  107. : super(_value, _then);
  108. /// Create a copy of SyncResponseDto
  109. /// with the given fields replaced by the non-null parameter values.
  110. @pragma('vm:prefer-inline')
  111. @override
  112. $Res call({
  113. Object? status = null,
  114. Object? statusText = null,
  115. Object? idAssegnato = freezed,
  116. Object? messages = null,
  117. Object? validationErrors = null,
  118. }) {
  119. return _then(_$SyncResponseDtoImpl(
  120. status: null == status
  121. ? _value.status
  122. : status // ignore: cast_nullable_to_non_nullable
  123. as int,
  124. statusText: null == statusText
  125. ? _value.statusText
  126. : statusText // ignore: cast_nullable_to_non_nullable
  127. as String,
  128. idAssegnato: freezed == idAssegnato
  129. ? _value.idAssegnato
  130. : idAssegnato // ignore: cast_nullable_to_non_nullable
  131. as int?,
  132. messages: null == messages
  133. ? _value._messages
  134. : messages // ignore: cast_nullable_to_non_nullable
  135. as List<String>,
  136. validationErrors: null == validationErrors
  137. ? _value._validationErrors
  138. : validationErrors // ignore: cast_nullable_to_non_nullable
  139. as List<String>,
  140. ));
  141. }
  142. }
  143. /// @nodoc
  144. @JsonSerializable()
  145. class _$SyncResponseDtoImpl extends _SyncResponseDto {
  146. const _$SyncResponseDtoImpl(
  147. {this.status = 0,
  148. this.statusText = 'OK',
  149. this.idAssegnato,
  150. final List<String> messages = const [],
  151. final List<String> validationErrors = const []})
  152. : _messages = messages,
  153. _validationErrors = validationErrors,
  154. super._();
  155. factory _$SyncResponseDtoImpl.fromJson(Map<String, dynamic> json) =>
  156. _$$SyncResponseDtoImplFromJson(json);
  157. @override
  158. @JsonKey()
  159. final int status;
  160. @override
  161. @JsonKey()
  162. final String statusText;
  163. @override
  164. final int? idAssegnato;
  165. final List<String> _messages;
  166. @override
  167. @JsonKey()
  168. List<String> get messages {
  169. if (_messages is EqualUnmodifiableListView) return _messages;
  170. // ignore: implicit_dynamic_type
  171. return EqualUnmodifiableListView(_messages);
  172. }
  173. final List<String> _validationErrors;
  174. @override
  175. @JsonKey()
  176. List<String> get validationErrors {
  177. if (_validationErrors is EqualUnmodifiableListView)
  178. return _validationErrors;
  179. // ignore: implicit_dynamic_type
  180. return EqualUnmodifiableListView(_validationErrors);
  181. }
  182. @override
  183. String toString() {
  184. return 'SyncResponseDto(status: $status, statusText: $statusText, idAssegnato: $idAssegnato, messages: $messages, validationErrors: $validationErrors)';
  185. }
  186. @override
  187. bool operator ==(Object other) {
  188. return identical(this, other) ||
  189. (other.runtimeType == runtimeType &&
  190. other is _$SyncResponseDtoImpl &&
  191. (identical(other.status, status) || other.status == status) &&
  192. (identical(other.statusText, statusText) ||
  193. other.statusText == statusText) &&
  194. (identical(other.idAssegnato, idAssegnato) ||
  195. other.idAssegnato == idAssegnato) &&
  196. const DeepCollectionEquality().equals(other._messages, _messages) &&
  197. const DeepCollectionEquality()
  198. .equals(other._validationErrors, _validationErrors));
  199. }
  200. @JsonKey(includeFromJson: false, includeToJson: false)
  201. @override
  202. int get hashCode => Object.hash(
  203. runtimeType,
  204. status,
  205. statusText,
  206. idAssegnato,
  207. const DeepCollectionEquality().hash(_messages),
  208. const DeepCollectionEquality().hash(_validationErrors));
  209. /// Create a copy of SyncResponseDto
  210. /// with the given fields replaced by the non-null parameter values.
  211. @JsonKey(includeFromJson: false, includeToJson: false)
  212. @override
  213. @pragma('vm:prefer-inline')
  214. _$$SyncResponseDtoImplCopyWith<_$SyncResponseDtoImpl> get copyWith =>
  215. __$$SyncResponseDtoImplCopyWithImpl<_$SyncResponseDtoImpl>(
  216. this, _$identity);
  217. @override
  218. Map<String, dynamic> toJson() {
  219. return _$$SyncResponseDtoImplToJson(
  220. this,
  221. );
  222. }
  223. }
  224. abstract class _SyncResponseDto extends SyncResponseDto {
  225. const factory _SyncResponseDto(
  226. {final int status,
  227. final String statusText,
  228. final int? idAssegnato,
  229. final List<String> messages,
  230. final List<String> validationErrors}) = _$SyncResponseDtoImpl;
  231. const _SyncResponseDto._() : super._();
  232. factory _SyncResponseDto.fromJson(Map<String, dynamic> json) =
  233. _$SyncResponseDtoImpl.fromJson;
  234. @override
  235. int get status;
  236. @override
  237. String get statusText;
  238. @override
  239. int? get idAssegnato;
  240. @override
  241. List<String> get messages;
  242. @override
  243. List<String> get validationErrors;
  244. /// Create a copy of SyncResponseDto
  245. /// with the given fields replaced by the non-null parameter values.
  246. @override
  247. @JsonKey(includeFromJson: false, includeToJson: false)
  248. _$$SyncResponseDtoImplCopyWith<_$SyncResponseDtoImpl> get copyWith =>
  249. throw _privateConstructorUsedError;
  250. }