modifyOptionGroup method

Future<ModifyOptionGroupResult> modifyOptionGroup({
  1. required String optionGroupName,
  2. bool? applyImmediately,
  3. List<OptionConfiguration>? optionsToInclude,
  4. List<String>? optionsToRemove,
})

Modifies an existing option group.

May throw InvalidOptionGroupStateFault. May throw OptionGroupNotFoundFault.

Parameter optionGroupName : The name of the option group to be modified.

Permanent options, such as the TDE option for Oracle Advanced Security TDE, can't be removed from an option group, and that option group can't be removed from a DB instance once it is associated with a DB instance

Parameter applyImmediately : A value that indicates whether to apply the change immediately or during the next maintenance window for each instance associated with the option group.

Parameter optionsToInclude : Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.

Parameter optionsToRemove : Options in this list are removed from the option group.

Implementation

Future<ModifyOptionGroupResult> modifyOptionGroup({
  required String optionGroupName,
  bool? applyImmediately,
  List<OptionConfiguration>? optionsToInclude,
  List<String>? optionsToRemove,
}) async {
  ArgumentError.checkNotNull(optionGroupName, 'optionGroupName');
  final $request = <String, dynamic>{};
  $request['OptionGroupName'] = optionGroupName;
  applyImmediately?.also((arg) => $request['ApplyImmediately'] = arg);
  optionsToInclude?.also((arg) => $request['OptionsToInclude'] = arg);
  optionsToRemove?.also((arg) => $request['OptionsToRemove'] = arg);
  final $result = await _protocol.send(
    $request,
    action: 'ModifyOptionGroup',
    version: '2014-10-31',
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    shape: shapes['ModifyOptionGroupMessage'],
    shapes: shapes,
    resultWrapper: 'ModifyOptionGroupResult',
  );
  return ModifyOptionGroupResult.fromXml($result);
}