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