toJson method
Serialize to a JSON-encodable map, omitting absent members.
Implementation
Map<String, dynamic> toJson() => <String, dynamic>{
'id': id,
'name': name,
'sizeBytes': sizeBytes,
'sha256': sha256,
if (contentType != null) 'contentType': contentType!,
};