riskReferenceSets method
Lists every set this plane publishes, with its version and how fresh it is.
Lists every set this plane publishes, with its version and how fresh it is. Read the Stale and Refused lists first: they are the two ways this plane can be quietly wrong, and they are reported rather than inferred. A set in Refused answers nothing — it has never loaded, it is held by another component, or it names a source we hold no licence for.
Implementation
Future<ReferenceSetsOut?> riskReferenceSets() async {
final response = await riskReferenceSetsWithHttpInfo();
if (response.statusCode >= HttpStatus.badRequest) {
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
}
// When a remote server returns no body with a status of 204, we shall not decode it.
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
// FormatException when trying to decode an empty string.
if (response.body.isNotEmpty && response.statusCode != HttpStatus.noContent) {
return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'ReferenceSetsOut',) as ReferenceSetsOut;
}
return null;
}