getMetricPolicy method
Returns the metric policy for the specified container.
May throw ContainerInUseException.
May throw ContainerNotFoundException.
May throw InternalServerError.
May throw PolicyNotFoundException.
Parameter containerName :
The name of the container that is associated with the metric policy.
Implementation
Future<GetMetricPolicyOutput> getMetricPolicy({
required String containerName,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'MediaStore_20170901.GetMetricPolicy'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'ContainerName': containerName,
},
);
return GetMetricPolicyOutput.fromJson(jsonResponse.body);
}