updateStopwordOptions method

Future<UpdateStopwordOptionsResponse> updateStopwordOptions({
  1. required String domainName,
  2. required String stopwords,
})

Configures stopwords for the search domain. Stopwords are used during indexing and when processing search requests. The maximum size of the stopwords dictionary is 10 KB.

May throw BaseException. May throw InternalException. May throw InvalidTypeException. May throw LimitExceededException. May throw ResourceNotFoundException.

Implementation

Future<UpdateStopwordOptionsResponse> updateStopwordOptions({
  required String domainName,
  required String stopwords,
}) async {
  ArgumentError.checkNotNull(domainName, 'domainName');
  _s.validateStringLength(
    'domainName',
    domainName,
    3,
    28,
    isRequired: true,
  );
  ArgumentError.checkNotNull(stopwords, 'stopwords');
  final $request = <String, dynamic>{};
  $request['DomainName'] = domainName;
  $request['Stopwords'] = stopwords;
  final $result = await _protocol.send(
    $request,
    action: 'UpdateStopwordOptions',
    version: '2011-02-01',
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    shape: shapes['UpdateStopwordOptionsRequest'],
    shapes: shapes,
    resultWrapper: 'UpdateStopwordOptionsResult',
  );
  return UpdateStopwordOptionsResponse.fromXml($result);
}