aws_sdk_rds/operation/create_integration/
_create_integration_output.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2
3/// <p>A zero-ETL integration with Amazon Redshift.</p>
4#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct CreateIntegrationOutput {
7    /// <p>The Amazon Resource Name (ARN) of the database used as the source for replication.</p>
8    pub source_arn: ::std::option::Option<::std::string::String>,
9    /// <p>The ARN of the Redshift data warehouse used as the target for replication.</p>
10    pub target_arn: ::std::option::Option<::std::string::String>,
11    /// <p>The name of the integration.</p>
12    pub integration_name: ::std::option::Option<::std::string::String>,
13    /// <p>The ARN of the integration.</p>
14    pub integration_arn: ::std::option::Option<::std::string::String>,
15    /// <p>The Amazon Web Services Key Management System (Amazon Web Services KMS) key identifier for the key used to to encrypt the integration.</p>
16    pub kms_key_id: ::std::option::Option<::std::string::String>,
17    /// <p>The encryption context for the integration. For more information, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context">Encryption context</a> in the <i>Amazon Web Services Key Management Service Developer Guide</i>.</p>
18    pub additional_encryption_context: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
19    /// <p>The current status of the integration.</p>
20    pub status: ::std::option::Option<crate::types::IntegrationStatus>,
21    /// <p>A list of tags.</p>
22    /// <p>For more information, see <a href="https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Tagging.html">Tagging Amazon RDS resources</a> in the <i>Amazon RDS User Guide</i> or <a href="https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_Tagging.html">Tagging Amazon Aurora and Amazon RDS resources</a> in the <i>Amazon Aurora User Guide</i>.</p>
23    pub tags: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>,
24    /// <p>The time when the integration was created, in Universal Coordinated Time (UTC).</p>
25    pub create_time: ::std::option::Option<::aws_smithy_types::DateTime>,
26    /// <p>Any errors associated with the integration.</p>
27    pub errors: ::std::option::Option<::std::vec::Vec<crate::types::IntegrationError>>,
28    /// <p>Data filters for the integration. These filters determine which tables from the source database are sent to the target Amazon Redshift data warehouse.</p>
29    pub data_filter: ::std::option::Option<::std::string::String>,
30    /// <p>A description of the integration.</p>
31    pub description: ::std::option::Option<::std::string::String>,
32    _request_id: Option<String>,
33}
34impl CreateIntegrationOutput {
35    /// <p>The Amazon Resource Name (ARN) of the database used as the source for replication.</p>
36    pub fn source_arn(&self) -> ::std::option::Option<&str> {
37        self.source_arn.as_deref()
38    }
39    /// <p>The ARN of the Redshift data warehouse used as the target for replication.</p>
40    pub fn target_arn(&self) -> ::std::option::Option<&str> {
41        self.target_arn.as_deref()
42    }
43    /// <p>The name of the integration.</p>
44    pub fn integration_name(&self) -> ::std::option::Option<&str> {
45        self.integration_name.as_deref()
46    }
47    /// <p>The ARN of the integration.</p>
48    pub fn integration_arn(&self) -> ::std::option::Option<&str> {
49        self.integration_arn.as_deref()
50    }
51    /// <p>The Amazon Web Services Key Management System (Amazon Web Services KMS) key identifier for the key used to to encrypt the integration.</p>
52    pub fn kms_key_id(&self) -> ::std::option::Option<&str> {
53        self.kms_key_id.as_deref()
54    }
55    /// <p>The encryption context for the integration. For more information, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context">Encryption context</a> in the <i>Amazon Web Services Key Management Service Developer Guide</i>.</p>
56    pub fn additional_encryption_context(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::string::String>> {
57        self.additional_encryption_context.as_ref()
58    }
59    /// <p>The current status of the integration.</p>
60    pub fn status(&self) -> ::std::option::Option<&crate::types::IntegrationStatus> {
61        self.status.as_ref()
62    }
63    /// <p>A list of tags.</p>
64    /// <p>For more information, see <a href="https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Tagging.html">Tagging Amazon RDS resources</a> in the <i>Amazon RDS User Guide</i> or <a href="https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_Tagging.html">Tagging Amazon Aurora and Amazon RDS resources</a> in the <i>Amazon Aurora User Guide</i>.</p>
65    ///
66    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.tags.is_none()`.
67    pub fn tags(&self) -> &[crate::types::Tag] {
68        self.tags.as_deref().unwrap_or_default()
69    }
70    /// <p>The time when the integration was created, in Universal Coordinated Time (UTC).</p>
71    pub fn create_time(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
72        self.create_time.as_ref()
73    }
74    /// <p>Any errors associated with the integration.</p>
75    ///
76    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.errors.is_none()`.
77    pub fn errors(&self) -> &[crate::types::IntegrationError] {
78        self.errors.as_deref().unwrap_or_default()
79    }
80    /// <p>Data filters for the integration. These filters determine which tables from the source database are sent to the target Amazon Redshift data warehouse.</p>
81    pub fn data_filter(&self) -> ::std::option::Option<&str> {
82        self.data_filter.as_deref()
83    }
84    /// <p>A description of the integration.</p>
85    pub fn description(&self) -> ::std::option::Option<&str> {
86        self.description.as_deref()
87    }
88}
89impl ::aws_types::request_id::RequestId for CreateIntegrationOutput {
90    fn request_id(&self) -> Option<&str> {
91        self._request_id.as_deref()
92    }
93}
94impl CreateIntegrationOutput {
95    /// Creates a new builder-style object to manufacture [`CreateIntegrationOutput`](crate::operation::create_integration::CreateIntegrationOutput).
96    pub fn builder() -> crate::operation::create_integration::builders::CreateIntegrationOutputBuilder {
97        crate::operation::create_integration::builders::CreateIntegrationOutputBuilder::default()
98    }
99}
100
101/// A builder for [`CreateIntegrationOutput`](crate::operation::create_integration::CreateIntegrationOutput).
102#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
103#[non_exhaustive]
104pub struct CreateIntegrationOutputBuilder {
105    pub(crate) source_arn: ::std::option::Option<::std::string::String>,
106    pub(crate) target_arn: ::std::option::Option<::std::string::String>,
107    pub(crate) integration_name: ::std::option::Option<::std::string::String>,
108    pub(crate) integration_arn: ::std::option::Option<::std::string::String>,
109    pub(crate) kms_key_id: ::std::option::Option<::std::string::String>,
110    pub(crate) additional_encryption_context: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
111    pub(crate) status: ::std::option::Option<crate::types::IntegrationStatus>,
112    pub(crate) tags: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>,
113    pub(crate) create_time: ::std::option::Option<::aws_smithy_types::DateTime>,
114    pub(crate) errors: ::std::option::Option<::std::vec::Vec<crate::types::IntegrationError>>,
115    pub(crate) data_filter: ::std::option::Option<::std::string::String>,
116    pub(crate) description: ::std::option::Option<::std::string::String>,
117    _request_id: Option<String>,
118}
119impl CreateIntegrationOutputBuilder {
120    /// <p>The Amazon Resource Name (ARN) of the database used as the source for replication.</p>
121    pub fn source_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
122        self.source_arn = ::std::option::Option::Some(input.into());
123        self
124    }
125    /// <p>The Amazon Resource Name (ARN) of the database used as the source for replication.</p>
126    pub fn set_source_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
127        self.source_arn = input;
128        self
129    }
130    /// <p>The Amazon Resource Name (ARN) of the database used as the source for replication.</p>
131    pub fn get_source_arn(&self) -> &::std::option::Option<::std::string::String> {
132        &self.source_arn
133    }
134    /// <p>The ARN of the Redshift data warehouse used as the target for replication.</p>
135    pub fn target_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
136        self.target_arn = ::std::option::Option::Some(input.into());
137        self
138    }
139    /// <p>The ARN of the Redshift data warehouse used as the target for replication.</p>
140    pub fn set_target_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
141        self.target_arn = input;
142        self
143    }
144    /// <p>The ARN of the Redshift data warehouse used as the target for replication.</p>
145    pub fn get_target_arn(&self) -> &::std::option::Option<::std::string::String> {
146        &self.target_arn
147    }
148    /// <p>The name of the integration.</p>
149    pub fn integration_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
150        self.integration_name = ::std::option::Option::Some(input.into());
151        self
152    }
153    /// <p>The name of the integration.</p>
154    pub fn set_integration_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
155        self.integration_name = input;
156        self
157    }
158    /// <p>The name of the integration.</p>
159    pub fn get_integration_name(&self) -> &::std::option::Option<::std::string::String> {
160        &self.integration_name
161    }
162    /// <p>The ARN of the integration.</p>
163    pub fn integration_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
164        self.integration_arn = ::std::option::Option::Some(input.into());
165        self
166    }
167    /// <p>The ARN of the integration.</p>
168    pub fn set_integration_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
169        self.integration_arn = input;
170        self
171    }
172    /// <p>The ARN of the integration.</p>
173    pub fn get_integration_arn(&self) -> &::std::option::Option<::std::string::String> {
174        &self.integration_arn
175    }
176    /// <p>The Amazon Web Services Key Management System (Amazon Web Services KMS) key identifier for the key used to to encrypt the integration.</p>
177    pub fn kms_key_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
178        self.kms_key_id = ::std::option::Option::Some(input.into());
179        self
180    }
181    /// <p>The Amazon Web Services Key Management System (Amazon Web Services KMS) key identifier for the key used to to encrypt the integration.</p>
182    pub fn set_kms_key_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
183        self.kms_key_id = input;
184        self
185    }
186    /// <p>The Amazon Web Services Key Management System (Amazon Web Services KMS) key identifier for the key used to to encrypt the integration.</p>
187    pub fn get_kms_key_id(&self) -> &::std::option::Option<::std::string::String> {
188        &self.kms_key_id
189    }
190    /// Adds a key-value pair to `additional_encryption_context`.
191    ///
192    /// To override the contents of this collection use [`set_additional_encryption_context`](Self::set_additional_encryption_context).
193    ///
194    /// <p>The encryption context for the integration. For more information, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context">Encryption context</a> in the <i>Amazon Web Services Key Management Service Developer Guide</i>.</p>
195    pub fn additional_encryption_context(
196        mut self,
197        k: impl ::std::convert::Into<::std::string::String>,
198        v: impl ::std::convert::Into<::std::string::String>,
199    ) -> Self {
200        let mut hash_map = self.additional_encryption_context.unwrap_or_default();
201        hash_map.insert(k.into(), v.into());
202        self.additional_encryption_context = ::std::option::Option::Some(hash_map);
203        self
204    }
205    /// <p>The encryption context for the integration. For more information, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context">Encryption context</a> in the <i>Amazon Web Services Key Management Service Developer Guide</i>.</p>
206    pub fn set_additional_encryption_context(
207        mut self,
208        input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
209    ) -> Self {
210        self.additional_encryption_context = input;
211        self
212    }
213    /// <p>The encryption context for the integration. For more information, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#encrypt_context">Encryption context</a> in the <i>Amazon Web Services Key Management Service Developer Guide</i>.</p>
214    pub fn get_additional_encryption_context(
215        &self,
216    ) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
217        &self.additional_encryption_context
218    }
219    /// <p>The current status of the integration.</p>
220    pub fn status(mut self, input: crate::types::IntegrationStatus) -> Self {
221        self.status = ::std::option::Option::Some(input);
222        self
223    }
224    /// <p>The current status of the integration.</p>
225    pub fn set_status(mut self, input: ::std::option::Option<crate::types::IntegrationStatus>) -> Self {
226        self.status = input;
227        self
228    }
229    /// <p>The current status of the integration.</p>
230    pub fn get_status(&self) -> &::std::option::Option<crate::types::IntegrationStatus> {
231        &self.status
232    }
233    /// Appends an item to `tags`.
234    ///
235    /// To override the contents of this collection use [`set_tags`](Self::set_tags).
236    ///
237    /// <p>A list of tags.</p>
238    /// <p>For more information, see <a href="https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Tagging.html">Tagging Amazon RDS resources</a> in the <i>Amazon RDS User Guide</i> or <a href="https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_Tagging.html">Tagging Amazon Aurora and Amazon RDS resources</a> in the <i>Amazon Aurora User Guide</i>.</p>
239    pub fn tags(mut self, input: crate::types::Tag) -> Self {
240        let mut v = self.tags.unwrap_or_default();
241        v.push(input);
242        self.tags = ::std::option::Option::Some(v);
243        self
244    }
245    /// <p>A list of tags.</p>
246    /// <p>For more information, see <a href="https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Tagging.html">Tagging Amazon RDS resources</a> in the <i>Amazon RDS User Guide</i> or <a href="https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_Tagging.html">Tagging Amazon Aurora and Amazon RDS resources</a> in the <i>Amazon Aurora User Guide</i>.</p>
247    pub fn set_tags(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>) -> Self {
248        self.tags = input;
249        self
250    }
251    /// <p>A list of tags.</p>
252    /// <p>For more information, see <a href="https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Tagging.html">Tagging Amazon RDS resources</a> in the <i>Amazon RDS User Guide</i> or <a href="https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_Tagging.html">Tagging Amazon Aurora and Amazon RDS resources</a> in the <i>Amazon Aurora User Guide</i>.</p>
253    pub fn get_tags(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Tag>> {
254        &self.tags
255    }
256    /// <p>The time when the integration was created, in Universal Coordinated Time (UTC).</p>
257    pub fn create_time(mut self, input: ::aws_smithy_types::DateTime) -> Self {
258        self.create_time = ::std::option::Option::Some(input);
259        self
260    }
261    /// <p>The time when the integration was created, in Universal Coordinated Time (UTC).</p>
262    pub fn set_create_time(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
263        self.create_time = input;
264        self
265    }
266    /// <p>The time when the integration was created, in Universal Coordinated Time (UTC).</p>
267    pub fn get_create_time(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
268        &self.create_time
269    }
270    /// Appends an item to `errors`.
271    ///
272    /// To override the contents of this collection use [`set_errors`](Self::set_errors).
273    ///
274    /// <p>Any errors associated with the integration.</p>
275    pub fn errors(mut self, input: crate::types::IntegrationError) -> Self {
276        let mut v = self.errors.unwrap_or_default();
277        v.push(input);
278        self.errors = ::std::option::Option::Some(v);
279        self
280    }
281    /// <p>Any errors associated with the integration.</p>
282    pub fn set_errors(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::IntegrationError>>) -> Self {
283        self.errors = input;
284        self
285    }
286    /// <p>Any errors associated with the integration.</p>
287    pub fn get_errors(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::IntegrationError>> {
288        &self.errors
289    }
290    /// <p>Data filters for the integration. These filters determine which tables from the source database are sent to the target Amazon Redshift data warehouse.</p>
291    pub fn data_filter(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
292        self.data_filter = ::std::option::Option::Some(input.into());
293        self
294    }
295    /// <p>Data filters for the integration. These filters determine which tables from the source database are sent to the target Amazon Redshift data warehouse.</p>
296    pub fn set_data_filter(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
297        self.data_filter = input;
298        self
299    }
300    /// <p>Data filters for the integration. These filters determine which tables from the source database are sent to the target Amazon Redshift data warehouse.</p>
301    pub fn get_data_filter(&self) -> &::std::option::Option<::std::string::String> {
302        &self.data_filter
303    }
304    /// <p>A description of the integration.</p>
305    pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
306        self.description = ::std::option::Option::Some(input.into());
307        self
308    }
309    /// <p>A description of the integration.</p>
310    pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
311        self.description = input;
312        self
313    }
314    /// <p>A description of the integration.</p>
315    pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
316        &self.description
317    }
318    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
319        self._request_id = Some(request_id.into());
320        self
321    }
322
323    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
324        self._request_id = request_id;
325        self
326    }
327    /// Consumes the builder and constructs a [`CreateIntegrationOutput`](crate::operation::create_integration::CreateIntegrationOutput).
328    pub fn build(self) -> crate::operation::create_integration::CreateIntegrationOutput {
329        crate::operation::create_integration::CreateIntegrationOutput {
330            source_arn: self.source_arn,
331            target_arn: self.target_arn,
332            integration_name: self.integration_name,
333            integration_arn: self.integration_arn,
334            kms_key_id: self.kms_key_id,
335            additional_encryption_context: self.additional_encryption_context,
336            status: self.status,
337            tags: self.tags,
338            create_time: self.create_time,
339            errors: self.errors,
340            data_filter: self.data_filter,
341            description: self.description,
342            _request_id: self._request_id,
343        }
344    }
345}