@@ -19,6 +19,9 @@ mixin _$NetworkLaunchModel {
19
19
String get id;
20
20
@JsonKey (name: 'mission_name' )
21
21
String ? get missionName;
22
+ @TimestampSerializer ()
23
+ @JsonKey (name: 'launch_date_utc' )
24
+ DateTime ? get launchDate;
22
25
@JsonKey (name: 'rocket' )
23
26
NetworkRocketModel ? get rocket;
24
27
@JsonKey (name: 'launch_success' )
@@ -45,19 +48,21 @@ mixin _$NetworkLaunchModel {
45
48
(identical (other.id, id) || other.id == id) &&
46
49
(identical (other.missionName, missionName) ||
47
50
other.missionName == missionName) &&
51
+ (identical (other.launchDate, launchDate) ||
52
+ other.launchDate == launchDate) &&
48
53
(identical (other.rocket, rocket) || other.rocket == rocket) &&
49
54
(identical (other.success, success) || other.success == success) &&
50
55
(identical (other.links, links) || other.links == links));
51
56
}
52
57
53
58
@JsonKey (includeFromJson: false , includeToJson: false )
54
59
@override
55
- int get hashCode =>
56
- Object . hash ( runtimeType, id, missionName, rocket, success, links);
60
+ int get hashCode => Object . hash (
61
+ runtimeType, id, missionName, launchDate , rocket, success, links);
57
62
58
63
@override
59
64
String toString () {
60
- return 'NetworkLaunchModel(id: $id , missionName: $missionName , rocket: $rocket , success: $success , links: $links )' ;
65
+ return 'NetworkLaunchModel(id: $id , missionName: $missionName , launchDate: $ launchDate , rocket: $rocket , success: $success , links: $links )' ;
61
66
}
62
67
}
63
68
@@ -70,6 +75,9 @@ abstract mixin class $NetworkLaunchModelCopyWith<$Res> {
70
75
$Res call (
71
76
{@JsonKey (name: '_id' ) String id,
72
77
@JsonKey (name: 'mission_name' ) String ? missionName,
78
+ @TimestampSerializer ()
79
+ @JsonKey (name: 'launch_date_utc' )
80
+ DateTime ? launchDate,
73
81
@JsonKey (name: 'rocket' ) NetworkRocketModel ? rocket,
74
82
@JsonKey (name: 'launch_success' ) bool success,
75
83
@JsonKey (name: 'links' ) NetworkLaunchLinksModel ? links});
@@ -93,6 +101,7 @@ class _$NetworkLaunchModelCopyWithImpl<$Res>
93
101
$Res call ({
94
102
Object ? id = null ,
95
103
Object ? missionName = freezed,
104
+ Object ? launchDate = freezed,
96
105
Object ? rocket = freezed,
97
106
Object ? success = null ,
98
107
Object ? links = freezed,
@@ -106,6 +115,10 @@ class _$NetworkLaunchModelCopyWithImpl<$Res>
106
115
? _self.missionName
107
116
: missionName // ignore: cast_nullable_to_non_nullable
108
117
as String ? ,
118
+ launchDate: freezed == launchDate
119
+ ? _self.launchDate
120
+ : launchDate // ignore: cast_nullable_to_non_nullable
121
+ as DateTime ? ,
109
122
rocket: freezed == rocket
110
123
? _self.rocket
111
124
: rocket // ignore: cast_nullable_to_non_nullable
@@ -156,6 +169,7 @@ class _NetworkLaunchModel extends NetworkLaunchModel {
156
169
const _NetworkLaunchModel (
157
170
{@JsonKey (name: '_id' ) required this .id,
158
171
@JsonKey (name: 'mission_name' ) this .missionName,
172
+ @TimestampSerializer () @JsonKey (name: 'launch_date_utc' ) this .launchDate,
159
173
@JsonKey (name: 'rocket' ) this .rocket,
160
174
@JsonKey (name: 'launch_success' ) this .success = false ,
161
175
@JsonKey (name: 'links' ) this .links})
@@ -170,6 +184,10 @@ class _NetworkLaunchModel extends NetworkLaunchModel {
170
184
@JsonKey (name: 'mission_name' )
171
185
final String ? missionName;
172
186
@override
187
+ @TimestampSerializer ()
188
+ @JsonKey (name: 'launch_date_utc' )
189
+ final DateTime ? launchDate;
190
+ @override
173
191
@JsonKey (name: 'rocket' )
174
192
final NetworkRocketModel ? rocket;
175
193
@override
@@ -202,19 +220,21 @@ class _NetworkLaunchModel extends NetworkLaunchModel {
202
220
(identical (other.id, id) || other.id == id) &&
203
221
(identical (other.missionName, missionName) ||
204
222
other.missionName == missionName) &&
223
+ (identical (other.launchDate, launchDate) ||
224
+ other.launchDate == launchDate) &&
205
225
(identical (other.rocket, rocket) || other.rocket == rocket) &&
206
226
(identical (other.success, success) || other.success == success) &&
207
227
(identical (other.links, links) || other.links == links));
208
228
}
209
229
210
230
@JsonKey (includeFromJson: false , includeToJson: false )
211
231
@override
212
- int get hashCode =>
213
- Object . hash ( runtimeType, id, missionName, rocket, success, links);
232
+ int get hashCode => Object . hash (
233
+ runtimeType, id, missionName, launchDate , rocket, success, links);
214
234
215
235
@override
216
236
String toString () {
217
- return 'NetworkLaunchModel(id: $id , missionName: $missionName , rocket: $rocket , success: $success , links: $links )' ;
237
+ return 'NetworkLaunchModel(id: $id , missionName: $missionName , launchDate: $ launchDate , rocket: $rocket , success: $success , links: $links )' ;
218
238
}
219
239
}
220
240
@@ -229,6 +249,9 @@ abstract mixin class _$NetworkLaunchModelCopyWith<$Res>
229
249
$Res call (
230
250
{@JsonKey (name: '_id' ) String id,
231
251
@JsonKey (name: 'mission_name' ) String ? missionName,
252
+ @TimestampSerializer ()
253
+ @JsonKey (name: 'launch_date_utc' )
254
+ DateTime ? launchDate,
232
255
@JsonKey (name: 'rocket' ) NetworkRocketModel ? rocket,
233
256
@JsonKey (name: 'launch_success' ) bool success,
234
257
@JsonKey (name: 'links' ) NetworkLaunchLinksModel ? links});
@@ -254,6 +277,7 @@ class __$NetworkLaunchModelCopyWithImpl<$Res>
254
277
$Res call ({
255
278
Object ? id = null ,
256
279
Object ? missionName = freezed,
280
+ Object ? launchDate = freezed,
257
281
Object ? rocket = freezed,
258
282
Object ? success = null ,
259
283
Object ? links = freezed,
@@ -267,6 +291,10 @@ class __$NetworkLaunchModelCopyWithImpl<$Res>
267
291
? _self.missionName
268
292
: missionName // ignore: cast_nullable_to_non_nullable
269
293
as String ? ,
294
+ launchDate: freezed == launchDate
295
+ ? _self.launchDate
296
+ : launchDate // ignore: cast_nullable_to_non_nullable
297
+ as DateTime ? ,
270
298
rocket: freezed == rocket
271
299
? _self.rocket
272
300
: rocket // ignore: cast_nullable_to_non_nullable
@@ -315,9 +343,9 @@ class __$NetworkLaunchModelCopyWithImpl<$Res>
315
343
mixin _$NetworkRocketModel {
316
344
@JsonKey (name: 'rocket_id' )
317
345
String get id;
318
- @JsonKey (name: 'type ' )
346
+ @JsonKey (name: 'rocket_type ' )
319
347
String ? get type;
320
- @JsonKey (name: 'name ' )
348
+ @JsonKey (name: 'rocket_name ' )
321
349
String ? get name;
322
350
323
351
/// Create a copy of NetworkRocketModel
@@ -359,8 +387,8 @@ abstract mixin class $NetworkRocketModelCopyWith<$Res> {
359
387
@useResult
360
388
$Res call (
361
389
{@JsonKey (name: 'rocket_id' ) String id,
362
- @JsonKey (name: 'type ' ) String ? type,
363
- @JsonKey (name: 'name ' ) String ? name});
390
+ @JsonKey (name: 'rocket_type ' ) String ? type,
391
+ @JsonKey (name: 'rocket_name ' ) String ? name});
364
392
}
365
393
366
394
/// @nodoc
@@ -402,8 +430,8 @@ class _$NetworkRocketModelCopyWithImpl<$Res>
402
430
class _NetworkRocketModel extends NetworkRocketModel {
403
431
const _NetworkRocketModel (
404
432
{@JsonKey (name: 'rocket_id' ) required this .id,
405
- @JsonKey (name: 'type ' ) this .type,
406
- @JsonKey (name: 'name ' ) this .name})
433
+ @JsonKey (name: 'rocket_type ' ) this .type,
434
+ @JsonKey (name: 'rocket_name ' ) this .name})
407
435
: super ._();
408
436
factory _NetworkRocketModel .fromJson (Map <String , dynamic > json) =>
409
437
_$NetworkRocketModelFromJson (json);
@@ -412,10 +440,10 @@ class _NetworkRocketModel extends NetworkRocketModel {
412
440
@JsonKey (name: 'rocket_id' )
413
441
final String id;
414
442
@override
415
- @JsonKey (name: 'type ' )
443
+ @JsonKey (name: 'rocket_type ' )
416
444
final String ? type;
417
445
@override
418
- @JsonKey (name: 'name ' )
446
+ @JsonKey (name: 'rocket_name ' )
419
447
final String ? name;
420
448
421
449
/// Create a copy of NetworkRocketModel
@@ -463,8 +491,8 @@ abstract mixin class _$NetworkRocketModelCopyWith<$Res>
463
491
@useResult
464
492
$Res call (
465
493
{@JsonKey (name: 'rocket_id' ) String id,
466
- @JsonKey (name: 'type ' ) String ? type,
467
- @JsonKey (name: 'name ' ) String ? name});
494
+ @JsonKey (name: 'rocket_type ' ) String ? type,
495
+ @JsonKey (name: 'rocket_name ' ) String ? name});
468
496
}
469
497
470
498
/// @nodoc
0 commit comments