1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
/// <p></p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct ModifyOptionGroupInput {
/// <p>The name of the option group to be modified.</p>
/// <p>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</p>
pub option_group_name: ::std::option::Option<::std::string::String>,
/// <p>Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.</p>
pub options_to_include: ::std::option::Option<::std::vec::Vec<crate::types::OptionConfiguration>>,
/// <p>Options in this list are removed from the option group.</p>
pub options_to_remove: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
/// <p>Specifies whether to apply the change immediately or during the next maintenance window for each instance associated with the option group.</p>
pub apply_immediately: ::std::option::Option<bool>,
}
impl ModifyOptionGroupInput {
/// <p>The name of the option group to be modified.</p>
/// <p>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</p>
pub fn option_group_name(&self) -> ::std::option::Option<&str> {
self.option_group_name.as_deref()
}
/// <p>Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.</p>
///
/// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.options_to_include.is_none()`.
pub fn options_to_include(&self) -> &[crate::types::OptionConfiguration] {
self.options_to_include.as_deref().unwrap_or_default()
}
/// <p>Options in this list are removed from the option group.</p>
///
/// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.options_to_remove.is_none()`.
pub fn options_to_remove(&self) -> &[::std::string::String] {
self.options_to_remove.as_deref().unwrap_or_default()
}
/// <p>Specifies whether to apply the change immediately or during the next maintenance window for each instance associated with the option group.</p>
pub fn apply_immediately(&self) -> ::std::option::Option<bool> {
self.apply_immediately
}
}
impl ModifyOptionGroupInput {
/// Creates a new builder-style object to manufacture [`ModifyOptionGroupInput`](crate::operation::modify_option_group::ModifyOptionGroupInput).
pub fn builder() -> crate::operation::modify_option_group::builders::ModifyOptionGroupInputBuilder {
crate::operation::modify_option_group::builders::ModifyOptionGroupInputBuilder::default()
}
}
/// A builder for [`ModifyOptionGroupInput`](crate::operation::modify_option_group::ModifyOptionGroupInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct ModifyOptionGroupInputBuilder {
pub(crate) option_group_name: ::std::option::Option<::std::string::String>,
pub(crate) options_to_include: ::std::option::Option<::std::vec::Vec<crate::types::OptionConfiguration>>,
pub(crate) options_to_remove: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
pub(crate) apply_immediately: ::std::option::Option<bool>,
}
impl ModifyOptionGroupInputBuilder {
/// <p>The name of the option group to be modified.</p>
/// <p>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</p>
/// This field is required.
pub fn option_group_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.option_group_name = ::std::option::Option::Some(input.into());
self
}
/// <p>The name of the option group to be modified.</p>
/// <p>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</p>
pub fn set_option_group_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.option_group_name = input;
self
}
/// <p>The name of the option group to be modified.</p>
/// <p>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</p>
pub fn get_option_group_name(&self) -> &::std::option::Option<::std::string::String> {
&self.option_group_name
}
/// Appends an item to `options_to_include`.
///
/// To override the contents of this collection use [`set_options_to_include`](Self::set_options_to_include).
///
/// <p>Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.</p>
pub fn options_to_include(mut self, input: crate::types::OptionConfiguration) -> Self {
let mut v = self.options_to_include.unwrap_or_default();
v.push(input);
self.options_to_include = ::std::option::Option::Some(v);
self
}
/// <p>Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.</p>
pub fn set_options_to_include(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::OptionConfiguration>>) -> Self {
self.options_to_include = input;
self
}
/// <p>Options in this list are added to the option group or, if already present, the specified configuration is used to update the existing configuration.</p>
pub fn get_options_to_include(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::OptionConfiguration>> {
&self.options_to_include
}
/// Appends an item to `options_to_remove`.
///
/// To override the contents of this collection use [`set_options_to_remove`](Self::set_options_to_remove).
///
/// <p>Options in this list are removed from the option group.</p>
pub fn options_to_remove(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
let mut v = self.options_to_remove.unwrap_or_default();
v.push(input.into());
self.options_to_remove = ::std::option::Option::Some(v);
self
}
/// <p>Options in this list are removed from the option group.</p>
pub fn set_options_to_remove(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
self.options_to_remove = input;
self
}
/// <p>Options in this list are removed from the option group.</p>
pub fn get_options_to_remove(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
&self.options_to_remove
}
/// <p>Specifies whether to apply the change immediately or during the next maintenance window for each instance associated with the option group.</p>
pub fn apply_immediately(mut self, input: bool) -> Self {
self.apply_immediately = ::std::option::Option::Some(input);
self
}
/// <p>Specifies whether to apply the change immediately or during the next maintenance window for each instance associated with the option group.</p>
pub fn set_apply_immediately(mut self, input: ::std::option::Option<bool>) -> Self {
self.apply_immediately = input;
self
}
/// <p>Specifies whether to apply the change immediately or during the next maintenance window for each instance associated with the option group.</p>
pub fn get_apply_immediately(&self) -> &::std::option::Option<bool> {
&self.apply_immediately
}
/// Consumes the builder and constructs a [`ModifyOptionGroupInput`](crate::operation::modify_option_group::ModifyOptionGroupInput).
pub fn build(
self,
) -> ::std::result::Result<crate::operation::modify_option_group::ModifyOptionGroupInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::modify_option_group::ModifyOptionGroupInput {
option_group_name: self.option_group_name,
options_to_include: self.options_to_include,
options_to_remove: self.options_to_remove,
apply_immediately: self.apply_immediately,
})
}
}