aws_sdk_redshiftserverless/operation/create_namespace/
builders.rs1pub use crate::operation::create_namespace::_create_namespace_output::CreateNamespaceOutputBuilder;
3
4pub use crate::operation::create_namespace::_create_namespace_input::CreateNamespaceInputBuilder;
5
6impl crate::operation::create_namespace::builders::CreateNamespaceInputBuilder {
7 pub async fn send_with(
9 self,
10 client: &crate::Client,
11 ) -> ::std::result::Result<
12 crate::operation::create_namespace::CreateNamespaceOutput,
13 ::aws_smithy_runtime_api::client::result::SdkError<
14 crate::operation::create_namespace::CreateNamespaceError,
15 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
16 >,
17 > {
18 let mut fluent_builder = client.create_namespace();
19 fluent_builder.inner = self;
20 fluent_builder.send().await
21 }
22}
23#[derive(::std::clone::Clone, ::std::fmt::Debug)]
27pub struct CreateNamespaceFluentBuilder {
28 handle: ::std::sync::Arc<crate::client::Handle>,
29 inner: crate::operation::create_namespace::builders::CreateNamespaceInputBuilder,
30 config_override: ::std::option::Option<crate::config::Builder>,
31}
32impl
33 crate::client::customize::internal::CustomizableSend<
34 crate::operation::create_namespace::CreateNamespaceOutput,
35 crate::operation::create_namespace::CreateNamespaceError,
36 > for CreateNamespaceFluentBuilder
37{
38 fn send(
39 self,
40 config_override: crate::config::Builder,
41 ) -> crate::client::customize::internal::BoxFuture<
42 crate::client::customize::internal::SendResult<
43 crate::operation::create_namespace::CreateNamespaceOutput,
44 crate::operation::create_namespace::CreateNamespaceError,
45 >,
46 > {
47 ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
48 }
49}
50impl CreateNamespaceFluentBuilder {
51 pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
53 Self {
54 handle,
55 inner: ::std::default::Default::default(),
56 config_override: ::std::option::Option::None,
57 }
58 }
59 pub fn as_input(&self) -> &crate::operation::create_namespace::builders::CreateNamespaceInputBuilder {
61 &self.inner
62 }
63 pub async fn send(
72 self,
73 ) -> ::std::result::Result<
74 crate::operation::create_namespace::CreateNamespaceOutput,
75 ::aws_smithy_runtime_api::client::result::SdkError<
76 crate::operation::create_namespace::CreateNamespaceError,
77 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
78 >,
79 > {
80 let input = self
81 .inner
82 .build()
83 .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
84 let runtime_plugins = crate::operation::create_namespace::CreateNamespace::operation_runtime_plugins(
85 self.handle.runtime_plugins.clone(),
86 &self.handle.conf,
87 self.config_override,
88 );
89 crate::operation::create_namespace::CreateNamespace::orchestrate(&runtime_plugins, input).await
90 }
91
92 pub fn customize(
94 self,
95 ) -> crate::client::customize::CustomizableOperation<
96 crate::operation::create_namespace::CreateNamespaceOutput,
97 crate::operation::create_namespace::CreateNamespaceError,
98 Self,
99 > {
100 crate::client::customize::CustomizableOperation::new(self)
101 }
102 pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
103 self.set_config_override(::std::option::Option::Some(config_override.into()));
104 self
105 }
106
107 pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
108 self.config_override = config_override;
109 self
110 }
111 pub fn namespace_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
113 self.inner = self.inner.namespace_name(input.into());
114 self
115 }
116 pub fn set_namespace_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
118 self.inner = self.inner.set_namespace_name(input);
119 self
120 }
121 pub fn get_namespace_name(&self) -> &::std::option::Option<::std::string::String> {
123 self.inner.get_namespace_name()
124 }
125 pub fn admin_username(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
127 self.inner = self.inner.admin_username(input.into());
128 self
129 }
130 pub fn set_admin_username(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
132 self.inner = self.inner.set_admin_username(input);
133 self
134 }
135 pub fn get_admin_username(&self) -> &::std::option::Option<::std::string::String> {
137 self.inner.get_admin_username()
138 }
139 pub fn admin_user_password(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
142 self.inner = self.inner.admin_user_password(input.into());
143 self
144 }
145 pub fn set_admin_user_password(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
148 self.inner = self.inner.set_admin_user_password(input);
149 self
150 }
151 pub fn get_admin_user_password(&self) -> &::std::option::Option<::std::string::String> {
154 self.inner.get_admin_user_password()
155 }
156 pub fn db_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
158 self.inner = self.inner.db_name(input.into());
159 self
160 }
161 pub fn set_db_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
163 self.inner = self.inner.set_db_name(input);
164 self
165 }
166 pub fn get_db_name(&self) -> &::std::option::Option<::std::string::String> {
168 self.inner.get_db_name()
169 }
170 pub fn kms_key_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
172 self.inner = self.inner.kms_key_id(input.into());
173 self
174 }
175 pub fn set_kms_key_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
177 self.inner = self.inner.set_kms_key_id(input);
178 self
179 }
180 pub fn get_kms_key_id(&self) -> &::std::option::Option<::std::string::String> {
182 self.inner.get_kms_key_id()
183 }
184 pub fn default_iam_role_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
186 self.inner = self.inner.default_iam_role_arn(input.into());
187 self
188 }
189 pub fn set_default_iam_role_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
191 self.inner = self.inner.set_default_iam_role_arn(input);
192 self
193 }
194 pub fn get_default_iam_role_arn(&self) -> &::std::option::Option<::std::string::String> {
196 self.inner.get_default_iam_role_arn()
197 }
198 pub fn iam_roles(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
205 self.inner = self.inner.iam_roles(input.into());
206 self
207 }
208 pub fn set_iam_roles(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
210 self.inner = self.inner.set_iam_roles(input);
211 self
212 }
213 pub fn get_iam_roles(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
215 self.inner.get_iam_roles()
216 }
217 pub fn log_exports(mut self, input: crate::types::LogExport) -> Self {
224 self.inner = self.inner.log_exports(input);
225 self
226 }
227 pub fn set_log_exports(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::LogExport>>) -> Self {
229 self.inner = self.inner.set_log_exports(input);
230 self
231 }
232 pub fn get_log_exports(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::LogExport>> {
234 self.inner.get_log_exports()
235 }
236 pub fn tags(mut self, input: crate::types::Tag) -> Self {
243 self.inner = self.inner.tags(input);
244 self
245 }
246 pub fn set_tags(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>) -> Self {
248 self.inner = self.inner.set_tags(input);
249 self
250 }
251 pub fn get_tags(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Tag>> {
253 self.inner.get_tags()
254 }
255 pub fn manage_admin_password(mut self, input: bool) -> Self {
257 self.inner = self.inner.manage_admin_password(input);
258 self
259 }
260 pub fn set_manage_admin_password(mut self, input: ::std::option::Option<bool>) -> Self {
262 self.inner = self.inner.set_manage_admin_password(input);
263 self
264 }
265 pub fn get_manage_admin_password(&self) -> &::std::option::Option<bool> {
267 self.inner.get_manage_admin_password()
268 }
269 pub fn admin_password_secret_kms_key_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
271 self.inner = self.inner.admin_password_secret_kms_key_id(input.into());
272 self
273 }
274 pub fn set_admin_password_secret_kms_key_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
276 self.inner = self.inner.set_admin_password_secret_kms_key_id(input);
277 self
278 }
279 pub fn get_admin_password_secret_kms_key_id(&self) -> &::std::option::Option<::std::string::String> {
281 self.inner.get_admin_password_secret_kms_key_id()
282 }
283 pub fn redshift_idc_application_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
285 self.inner = self.inner.redshift_idc_application_arn(input.into());
286 self
287 }
288 pub fn set_redshift_idc_application_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
290 self.inner = self.inner.set_redshift_idc_application_arn(input);
291 self
292 }
293 pub fn get_redshift_idc_application_arn(&self) -> &::std::option::Option<::std::string::String> {
295 self.inner.get_redshift_idc_application_arn()
296 }
297}