listFileShares method
Gets a list of the file shares for a specific S3 File Gateway, or the list of file shares that belong to the calling Amazon Web Services account. This operation is only supported for S3 File Gateways.
May throw InternalServerError.
May throw InvalidGatewayRequestException.
Parameter gatewayARN :
The Amazon Resource Name (ARN) of the gateway whose file shares you want
to list. If this field is not present, all file shares under your account
are listed.
Parameter limit :
The maximum number of file shares to return in the response. The value
must be an integer with a value greater than zero. Optional.
Parameter marker :
Opaque pagination token returned from a previous ListFileShares operation.
If present, Marker specifies where to continue the list from
after a previous call to ListFileShares. Optional.
Implementation
Future<ListFileSharesOutput> listFileShares({
String? gatewayARN,
int? limit,
String? marker,
}) async {
_s.validateNumRange(
'limit',
limit,
1,
1152921504606846976,
);
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'StorageGateway_20130630.ListFileShares'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
if (gatewayARN != null) 'GatewayARN': gatewayARN,
if (limit != null) 'Limit': limit,
if (marker != null) 'Marker': marker,
},
);
return ListFileSharesOutput.fromJson(jsonResponse.body);
}