Repository navigation
Expand file tree
/
Copy pathRelease.g.dart
More file actions
52 lines (48 loc) · 1.76 KB
/
Copy pathRelease.g.dart
File metadata and controls
52 lines (48 loc) · 1.76 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
// GENERATED CODE - DO NOT MODIFY BY HAND
part of 'Release.dart';
// **************************************************************************
// JsonSerializableGenerator
// **************************************************************************
Release _$ReleaseFromJson(Map<String, dynamic> json) {
return Release(
json['id'] as int,
json['tag_name'] as String,
json['target_commitish'] as String,
json['name'] as String,
json['body'] as String,
json['body_html'] as String,
json['tarball_url'] as String,
json['zipball_url'] as String,
json['draft'] as bool,
json['prerelease'] as bool,
json['created_at'] == null
? null
: DateTime.parse(json['created_at'] as String),
json['published_at'] == null
? null
: DateTime.parse(json['published_at'] as String),
json['author'] == null
? null
: User.fromJson(json['author'] as Map<String, dynamic>),
(json['assets'] as List)
?.map((e) => e == null
? null
: ReleaseAsset.fromJson(e as Map<String, dynamic>))
?.toList());
}
Map<String, dynamic> _$ReleaseToJson(Release instance) => <String, dynamic>{
'id': instance.id,
'tag_name': instance.tagName,
'target_commitish': instance.targetCommitish,
'name': instance.name,
'body': instance.body,
'body_html': instance.bodyHtml,
'tarball_url': instance.tarballUrl,
'zipball_url': instance.zipballUrl,
'draft': instance.draft,
'prerelease': instance.preRelease,
'created_at': instance.createdAt?.toIso8601String(),
'published_at': instance.publishedAt?.toIso8601String(),
'author': instance.author,
'assets': instance.assets
};