describeRankExpressions method

Future<DescribeRankExpressionsResponse> describeRankExpressions({
  1. required String domainName,
  2. List<String>? rankNames,
})

Gets the rank expressions configured for the search domain. Can be limited to specific rank expressions by name. Shows all rank expressions by default.

May throw BaseException. May throw InternalException. May throw ResourceNotFoundException.

Parameter rankNames : Limits the DescribeRankExpressions response to the specified fields.

Implementation

Future<DescribeRankExpressionsResponse> describeRankExpressions({
  required String domainName,
  List<String>? rankNames,
}) async {
  ArgumentError.checkNotNull(domainName, 'domainName');
  _s.validateStringLength(
    'domainName',
    domainName,
    3,
    28,
    isRequired: true,
  );
  final $request = <String, dynamic>{};
  $request['DomainName'] = domainName;
  rankNames?.also((arg) => $request['RankNames'] = arg);
  final $result = await _protocol.send(
    $request,
    action: 'DescribeRankExpressions',
    version: '2011-02-01',
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    shape: shapes['DescribeRankExpressionsRequest'],
    shapes: shapes,
    resultWrapper: 'DescribeRankExpressionsResult',
  );
  return DescribeRankExpressionsResponse.fromXml($result);
}