trash_bloc.freezed.dart 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431
  1. // GENERATED CODE - DO NOT MODIFY BY HAND
  2. // 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
  3. part of 'trash_bloc.dart';
  4. // **************************************************************************
  5. // FreezedGenerator
  6. // **************************************************************************
  7. T _$identity<T>(T value) => value;
  8. final _privateConstructorUsedError = UnsupportedError(
  9. '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 informations: https://github.com/rrousselGit/freezed#custom-getters-and-methods');
  10. /// @nodoc
  11. class _$TrashEventTearOff {
  12. const _$TrashEventTearOff();
  13. Initial initial() {
  14. return const Initial();
  15. }
  16. ReceiveTrash didReceiveTrash(List<Trash> trash) {
  17. return ReceiveTrash(
  18. trash,
  19. );
  20. }
  21. }
  22. /// @nodoc
  23. const $TrashEvent = _$TrashEventTearOff();
  24. /// @nodoc
  25. mixin _$TrashEvent {
  26. @optionalTypeArgs
  27. TResult when<TResult extends Object?>({
  28. required TResult Function() initial,
  29. required TResult Function(List<Trash> trash) didReceiveTrash,
  30. }) =>
  31. throw _privateConstructorUsedError;
  32. @optionalTypeArgs
  33. TResult maybeWhen<TResult extends Object?>({
  34. TResult Function()? initial,
  35. TResult Function(List<Trash> trash)? didReceiveTrash,
  36. required TResult orElse(),
  37. }) =>
  38. throw _privateConstructorUsedError;
  39. @optionalTypeArgs
  40. TResult map<TResult extends Object?>({
  41. required TResult Function(Initial value) initial,
  42. required TResult Function(ReceiveTrash value) didReceiveTrash,
  43. }) =>
  44. throw _privateConstructorUsedError;
  45. @optionalTypeArgs
  46. TResult maybeMap<TResult extends Object?>({
  47. TResult Function(Initial value)? initial,
  48. TResult Function(ReceiveTrash value)? didReceiveTrash,
  49. required TResult orElse(),
  50. }) =>
  51. throw _privateConstructorUsedError;
  52. }
  53. /// @nodoc
  54. abstract class $TrashEventCopyWith<$Res> {
  55. factory $TrashEventCopyWith(
  56. TrashEvent value, $Res Function(TrashEvent) then) =
  57. _$TrashEventCopyWithImpl<$Res>;
  58. }
  59. /// @nodoc
  60. class _$TrashEventCopyWithImpl<$Res> implements $TrashEventCopyWith<$Res> {
  61. _$TrashEventCopyWithImpl(this._value, this._then);
  62. final TrashEvent _value;
  63. // ignore: unused_field
  64. final $Res Function(TrashEvent) _then;
  65. }
  66. /// @nodoc
  67. abstract class $InitialCopyWith<$Res> {
  68. factory $InitialCopyWith(Initial value, $Res Function(Initial) then) =
  69. _$InitialCopyWithImpl<$Res>;
  70. }
  71. /// @nodoc
  72. class _$InitialCopyWithImpl<$Res> extends _$TrashEventCopyWithImpl<$Res>
  73. implements $InitialCopyWith<$Res> {
  74. _$InitialCopyWithImpl(Initial _value, $Res Function(Initial) _then)
  75. : super(_value, (v) => _then(v as Initial));
  76. @override
  77. Initial get _value => super._value as Initial;
  78. }
  79. /// @nodoc
  80. class _$Initial implements Initial {
  81. const _$Initial();
  82. @override
  83. String toString() {
  84. return 'TrashEvent.initial()';
  85. }
  86. @override
  87. bool operator ==(dynamic other) {
  88. return identical(this, other) || (other is Initial);
  89. }
  90. @override
  91. int get hashCode => runtimeType.hashCode;
  92. @override
  93. @optionalTypeArgs
  94. TResult when<TResult extends Object?>({
  95. required TResult Function() initial,
  96. required TResult Function(List<Trash> trash) didReceiveTrash,
  97. }) {
  98. return initial();
  99. }
  100. @override
  101. @optionalTypeArgs
  102. TResult maybeWhen<TResult extends Object?>({
  103. TResult Function()? initial,
  104. TResult Function(List<Trash> trash)? didReceiveTrash,
  105. required TResult orElse(),
  106. }) {
  107. if (initial != null) {
  108. return initial();
  109. }
  110. return orElse();
  111. }
  112. @override
  113. @optionalTypeArgs
  114. TResult map<TResult extends Object?>({
  115. required TResult Function(Initial value) initial,
  116. required TResult Function(ReceiveTrash value) didReceiveTrash,
  117. }) {
  118. return initial(this);
  119. }
  120. @override
  121. @optionalTypeArgs
  122. TResult maybeMap<TResult extends Object?>({
  123. TResult Function(Initial value)? initial,
  124. TResult Function(ReceiveTrash value)? didReceiveTrash,
  125. required TResult orElse(),
  126. }) {
  127. if (initial != null) {
  128. return initial(this);
  129. }
  130. return orElse();
  131. }
  132. }
  133. abstract class Initial implements TrashEvent {
  134. const factory Initial() = _$Initial;
  135. }
  136. /// @nodoc
  137. abstract class $ReceiveTrashCopyWith<$Res> {
  138. factory $ReceiveTrashCopyWith(
  139. ReceiveTrash value, $Res Function(ReceiveTrash) then) =
  140. _$ReceiveTrashCopyWithImpl<$Res>;
  141. $Res call({List<Trash> trash});
  142. }
  143. /// @nodoc
  144. class _$ReceiveTrashCopyWithImpl<$Res> extends _$TrashEventCopyWithImpl<$Res>
  145. implements $ReceiveTrashCopyWith<$Res> {
  146. _$ReceiveTrashCopyWithImpl(
  147. ReceiveTrash _value, $Res Function(ReceiveTrash) _then)
  148. : super(_value, (v) => _then(v as ReceiveTrash));
  149. @override
  150. ReceiveTrash get _value => super._value as ReceiveTrash;
  151. @override
  152. $Res call({
  153. Object? trash = freezed,
  154. }) {
  155. return _then(ReceiveTrash(
  156. trash == freezed
  157. ? _value.trash
  158. : trash // ignore: cast_nullable_to_non_nullable
  159. as List<Trash>,
  160. ));
  161. }
  162. }
  163. /// @nodoc
  164. class _$ReceiveTrash implements ReceiveTrash {
  165. const _$ReceiveTrash(this.trash);
  166. @override
  167. final List<Trash> trash;
  168. @override
  169. String toString() {
  170. return 'TrashEvent.didReceiveTrash(trash: $trash)';
  171. }
  172. @override
  173. bool operator ==(dynamic other) {
  174. return identical(this, other) ||
  175. (other is ReceiveTrash &&
  176. (identical(other.trash, trash) ||
  177. const DeepCollectionEquality().equals(other.trash, trash)));
  178. }
  179. @override
  180. int get hashCode =>
  181. runtimeType.hashCode ^ const DeepCollectionEquality().hash(trash);
  182. @JsonKey(ignore: true)
  183. @override
  184. $ReceiveTrashCopyWith<ReceiveTrash> get copyWith =>
  185. _$ReceiveTrashCopyWithImpl<ReceiveTrash>(this, _$identity);
  186. @override
  187. @optionalTypeArgs
  188. TResult when<TResult extends Object?>({
  189. required TResult Function() initial,
  190. required TResult Function(List<Trash> trash) didReceiveTrash,
  191. }) {
  192. return didReceiveTrash(trash);
  193. }
  194. @override
  195. @optionalTypeArgs
  196. TResult maybeWhen<TResult extends Object?>({
  197. TResult Function()? initial,
  198. TResult Function(List<Trash> trash)? didReceiveTrash,
  199. required TResult orElse(),
  200. }) {
  201. if (didReceiveTrash != null) {
  202. return didReceiveTrash(trash);
  203. }
  204. return orElse();
  205. }
  206. @override
  207. @optionalTypeArgs
  208. TResult map<TResult extends Object?>({
  209. required TResult Function(Initial value) initial,
  210. required TResult Function(ReceiveTrash value) didReceiveTrash,
  211. }) {
  212. return didReceiveTrash(this);
  213. }
  214. @override
  215. @optionalTypeArgs
  216. TResult maybeMap<TResult extends Object?>({
  217. TResult Function(Initial value)? initial,
  218. TResult Function(ReceiveTrash value)? didReceiveTrash,
  219. required TResult orElse(),
  220. }) {
  221. if (didReceiveTrash != null) {
  222. return didReceiveTrash(this);
  223. }
  224. return orElse();
  225. }
  226. }
  227. abstract class ReceiveTrash implements TrashEvent {
  228. const factory ReceiveTrash(List<Trash> trash) = _$ReceiveTrash;
  229. List<Trash> get trash => throw _privateConstructorUsedError;
  230. @JsonKey(ignore: true)
  231. $ReceiveTrashCopyWith<ReceiveTrash> get copyWith =>
  232. throw _privateConstructorUsedError;
  233. }
  234. /// @nodoc
  235. class _$TrashStateTearOff {
  236. const _$TrashStateTearOff();
  237. _TrashState call(
  238. {required List<Trash> objects,
  239. required Either<Unit, WorkspaceError> successOrFailure}) {
  240. return _TrashState(
  241. objects: objects,
  242. successOrFailure: successOrFailure,
  243. );
  244. }
  245. }
  246. /// @nodoc
  247. const $TrashState = _$TrashStateTearOff();
  248. /// @nodoc
  249. mixin _$TrashState {
  250. List<Trash> get objects => throw _privateConstructorUsedError;
  251. Either<Unit, WorkspaceError> get successOrFailure =>
  252. throw _privateConstructorUsedError;
  253. @JsonKey(ignore: true)
  254. $TrashStateCopyWith<TrashState> get copyWith =>
  255. throw _privateConstructorUsedError;
  256. }
  257. /// @nodoc
  258. abstract class $TrashStateCopyWith<$Res> {
  259. factory $TrashStateCopyWith(
  260. TrashState value, $Res Function(TrashState) then) =
  261. _$TrashStateCopyWithImpl<$Res>;
  262. $Res call(
  263. {List<Trash> objects, Either<Unit, WorkspaceError> successOrFailure});
  264. }
  265. /// @nodoc
  266. class _$TrashStateCopyWithImpl<$Res> implements $TrashStateCopyWith<$Res> {
  267. _$TrashStateCopyWithImpl(this._value, this._then);
  268. final TrashState _value;
  269. // ignore: unused_field
  270. final $Res Function(TrashState) _then;
  271. @override
  272. $Res call({
  273. Object? objects = freezed,
  274. Object? successOrFailure = freezed,
  275. }) {
  276. return _then(_value.copyWith(
  277. objects: objects == freezed
  278. ? _value.objects
  279. : objects // ignore: cast_nullable_to_non_nullable
  280. as List<Trash>,
  281. successOrFailure: successOrFailure == freezed
  282. ? _value.successOrFailure
  283. : successOrFailure // ignore: cast_nullable_to_non_nullable
  284. as Either<Unit, WorkspaceError>,
  285. ));
  286. }
  287. }
  288. /// @nodoc
  289. abstract class _$TrashStateCopyWith<$Res> implements $TrashStateCopyWith<$Res> {
  290. factory _$TrashStateCopyWith(
  291. _TrashState value, $Res Function(_TrashState) then) =
  292. __$TrashStateCopyWithImpl<$Res>;
  293. @override
  294. $Res call(
  295. {List<Trash> objects, Either<Unit, WorkspaceError> successOrFailure});
  296. }
  297. /// @nodoc
  298. class __$TrashStateCopyWithImpl<$Res> extends _$TrashStateCopyWithImpl<$Res>
  299. implements _$TrashStateCopyWith<$Res> {
  300. __$TrashStateCopyWithImpl(
  301. _TrashState _value, $Res Function(_TrashState) _then)
  302. : super(_value, (v) => _then(v as _TrashState));
  303. @override
  304. _TrashState get _value => super._value as _TrashState;
  305. @override
  306. $Res call({
  307. Object? objects = freezed,
  308. Object? successOrFailure = freezed,
  309. }) {
  310. return _then(_TrashState(
  311. objects: objects == freezed
  312. ? _value.objects
  313. : objects // ignore: cast_nullable_to_non_nullable
  314. as List<Trash>,
  315. successOrFailure: successOrFailure == freezed
  316. ? _value.successOrFailure
  317. : successOrFailure // ignore: cast_nullable_to_non_nullable
  318. as Either<Unit, WorkspaceError>,
  319. ));
  320. }
  321. }
  322. /// @nodoc
  323. class _$_TrashState implements _TrashState {
  324. const _$_TrashState({required this.objects, required this.successOrFailure});
  325. @override
  326. final List<Trash> objects;
  327. @override
  328. final Either<Unit, WorkspaceError> successOrFailure;
  329. @override
  330. String toString() {
  331. return 'TrashState(objects: $objects, successOrFailure: $successOrFailure)';
  332. }
  333. @override
  334. bool operator ==(dynamic other) {
  335. return identical(this, other) ||
  336. (other is _TrashState &&
  337. (identical(other.objects, objects) ||
  338. const DeepCollectionEquality()
  339. .equals(other.objects, objects)) &&
  340. (identical(other.successOrFailure, successOrFailure) ||
  341. const DeepCollectionEquality()
  342. .equals(other.successOrFailure, successOrFailure)));
  343. }
  344. @override
  345. int get hashCode =>
  346. runtimeType.hashCode ^
  347. const DeepCollectionEquality().hash(objects) ^
  348. const DeepCollectionEquality().hash(successOrFailure);
  349. @JsonKey(ignore: true)
  350. @override
  351. _$TrashStateCopyWith<_TrashState> get copyWith =>
  352. __$TrashStateCopyWithImpl<_TrashState>(this, _$identity);
  353. }
  354. abstract class _TrashState implements TrashState {
  355. const factory _TrashState(
  356. {required List<Trash> objects,
  357. required Either<Unit, WorkspaceError> successOrFailure}) = _$_TrashState;
  358. @override
  359. List<Trash> get objects => throw _privateConstructorUsedError;
  360. @override
  361. Either<Unit, WorkspaceError> get successOrFailure =>
  362. throw _privateConstructorUsedError;
  363. @override
  364. @JsonKey(ignore: true)
  365. _$TrashStateCopyWith<_TrashState> get copyWith =>
  366. throw _privateConstructorUsedError;
  367. }