PluginDetailsResult.fromJson constructor
PluginDetailsResult.fromJson(})
Implementation
factory PluginDetailsResult.fromJson(
JsonDecoder jsonDecoder,
String jsonPath,
Object? json, {
ClientUriConverter? clientUriConverter,
}) {
json ??= {};
if (json is Map) {
List<PluginDetails> plugins;
if (json.containsKey('plugins')) {
plugins = jsonDecoder.decodeList(
'$jsonPath.plugins',
json['plugins'],
(String jsonPath, Object? json) => PluginDetails.fromJson(
jsonDecoder,
jsonPath,
json,
clientUriConverter: clientUriConverter,
),
);
} else {
throw jsonDecoder.mismatch(jsonPath, "'plugins'", json);
}
return PluginDetailsResult(plugins);
} else {
throw jsonDecoder.mismatch(jsonPath, "'plugin.details result'", json);
}
}