listFileSystemAssociations method

Future<ListFileSystemAssociationsOutput> listFileSystemAssociations({
  1. String? gatewayARN,
  2. int? limit,
  3. String? marker,
})

Gets a list of FileSystemAssociationSummary objects. Each object contains a summary of a file system association. This operation is only supported for FSx File Gateways.

May throw InternalServerError. May throw InvalidGatewayRequestException.

Parameter limit : The maximum number of file system associations to return in the response. If present, Limit must be an integer with a value greater than zero. Optional.

Parameter marker : Opaque pagination token returned from a previous ListFileSystemAssociations operation. If present, Marker specifies where to continue the list from after a previous call to ListFileSystemAssociations. Optional.

Implementation

Future<ListFileSystemAssociationsOutput> listFileSystemAssociations({
  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.ListFileSystemAssociations'
  };
  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 ListFileSystemAssociationsOutput.fromJson(jsonResponse.body);
}