FileLinkUpdateOptions.fromJson constructor
FileLinkUpdateOptions.fromJson(
- Object? json
Implementation
factory FileLinkUpdateOptions.fromJson(Object? json) {
final map = (json as Map).cast<String, Object?>();
return FileLinkUpdateOptions(
expand: map['expand'] == null
? null
: (map['expand'] as List<Object?>)
.map((el) => (el as String))
.toList(),
expiresAt: map['expires_at'] == null
? null
: FileLinkExpiresAt.fromJson(map['expires_at']),
metadata: map['metadata'] == null
? null
: (map['metadata'] as Map).cast<String, Object?>().map((
key,
value,
) =>
MapEntry(
key,
(value as String),
)),
);
}