ListSinksResponse.fromJson constructor
ListSinksResponse.fromJson(
- Object? j
Implementation
factory ListSinksResponse.fromJson(Object? j) {
final json = j as Map<String, Object?>;
return ListSinksResponse(
sinks: switch (json['sinks']) {
null => [],
List<Object?> $1 => [for (final i in $1) LogSink.fromJson(i)],
_ => throw const FormatException('"sinks" is not a list'),
},
nextPageToken: switch (json['nextPageToken']) {
null => '',
Object $1 => decodeString($1),
},
);
}