updateConfigurationTemplate method
- required String applicationName,
- required String templateName,
- String? description,
- List<
ConfigurationOptionSetting> ? optionSettings, - List<
OptionSpecification> ? optionsToRemove,
Updates the specified configuration template to have the specified properties or configuration option values. Related Topics
May throw InsufficientPrivilegesException. May throw TooManyBucketsException.
Parameter applicationName
:
The name of the application associated with the configuration template to
update.
If no application is found with this name,
UpdateConfigurationTemplate
returns an
InvalidParameterValue
error.
Parameter templateName
:
The name of the configuration template to update.
If no configuration template is found with this name,
UpdateConfigurationTemplate
returns an
InvalidParameterValue
error.
Parameter description
:
A new description for the configuration.
Parameter optionSettings
:
A list of configuration option settings to update with the new specified
option value.
Parameter optionsToRemove
:
A list of configuration options to remove from the configuration set.
Constraint: You can remove only UserDefined
configuration
options.
Implementation
Future<ConfigurationSettingsDescription> updateConfigurationTemplate({
required String applicationName,
required String templateName,
String? description,
List<ConfigurationOptionSetting>? optionSettings,
List<OptionSpecification>? optionsToRemove,
}) async {
ArgumentError.checkNotNull(applicationName, 'applicationName');
_s.validateStringLength(
'applicationName',
applicationName,
1,
100,
isRequired: true,
);
ArgumentError.checkNotNull(templateName, 'templateName');
_s.validateStringLength(
'templateName',
templateName,
1,
100,
isRequired: true,
);
_s.validateStringLength(
'description',
description,
0,
200,
);
final $request = <String, dynamic>{};
$request['ApplicationName'] = applicationName;
$request['TemplateName'] = templateName;
description?.also((arg) => $request['Description'] = arg);
optionSettings?.also((arg) => $request['OptionSettings'] = arg);
optionsToRemove?.also((arg) => $request['OptionsToRemove'] = arg);
final $result = await _protocol.send(
$request,
action: 'UpdateConfigurationTemplate',
version: '2010-12-01',
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
shape: shapes['UpdateConfigurationTemplateMessage'],
shapes: shapes,
resultWrapper: 'UpdateConfigurationTemplateResult',
);
return ConfigurationSettingsDescription.fromXml($result);
}