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