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