Skip to main content

aws_sdk_appintegrations/operation/create_data_integration/
_create_data_integration_output.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2#[allow(missing_docs)] // documentation missing in model
3#[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct CreateDataIntegrationOutput {
6    /// <p>The Amazon Resource Name (ARN)</p>
7    pub arn: ::std::option::Option<::std::string::String>,
8    /// <p>A unique identifier.</p>
9    pub id: ::std::option::Option<::std::string::String>,
10    /// <p>The name of the DataIntegration.</p>
11    pub name: ::std::option::Option<::std::string::String>,
12    /// <p>A description of the DataIntegration.</p>
13    pub description: ::std::option::Option<::std::string::String>,
14    /// <p>The KMS key ARN for the DataIntegration.</p>
15    pub kms_key: ::std::option::Option<::std::string::String>,
16    /// <p>The URI of the data source.</p>
17    pub source_uri: ::std::option::Option<::std::string::String>,
18    /// <p>The name of the data and how often it should be pulled from the source.</p>
19    pub schedule_configuration: ::std::option::Option<crate::types::ScheduleConfiguration>,
20    /// <p>The tags used to organize, track, or control access for this resource. For example, { "tags": {"key1":"value1", "key2":"value2"} }.</p>
21    pub tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
22    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see <a href="https://aws.amazon.com/builders-library/making-retries-safe-with-idempotent-APIs/">Making retries safe with idempotent APIs</a>.</p>
23    pub client_token: ::std::option::Option<::std::string::String>,
24    /// <p>The configuration for what files should be pulled from the source.</p>
25    pub file_configuration: ::std::option::Option<crate::types::FileConfiguration>,
26    /// <p>The configuration for what data should be pulled from the source.</p>
27    pub object_configuration: ::std::option::Option<
28        ::std::collections::HashMap<
29            ::std::string::String,
30            ::std::collections::HashMap<::std::string::String, ::std::vec::Vec<::std::string::String>>,
31        >,
32    >,
33    _request_id: Option<String>,
34}
35impl CreateDataIntegrationOutput {
36    /// <p>The Amazon Resource Name (ARN)</p>
37    pub fn arn(&self) -> ::std::option::Option<&str> {
38        self.arn.as_deref()
39    }
40    /// <p>A unique identifier.</p>
41    pub fn id(&self) -> ::std::option::Option<&str> {
42        self.id.as_deref()
43    }
44    /// <p>The name of the DataIntegration.</p>
45    pub fn name(&self) -> ::std::option::Option<&str> {
46        self.name.as_deref()
47    }
48    /// <p>A description of the DataIntegration.</p>
49    pub fn description(&self) -> ::std::option::Option<&str> {
50        self.description.as_deref()
51    }
52    /// <p>The KMS key ARN for the DataIntegration.</p>
53    pub fn kms_key(&self) -> ::std::option::Option<&str> {
54        self.kms_key.as_deref()
55    }
56    /// <p>The URI of the data source.</p>
57    pub fn source_uri(&self) -> ::std::option::Option<&str> {
58        self.source_uri.as_deref()
59    }
60    /// <p>The name of the data and how often it should be pulled from the source.</p>
61    pub fn schedule_configuration(&self) -> ::std::option::Option<&crate::types::ScheduleConfiguration> {
62        self.schedule_configuration.as_ref()
63    }
64    /// <p>The tags used to organize, track, or control access for this resource. For example, { "tags": {"key1":"value1", "key2":"value2"} }.</p>
65    pub fn tags(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::string::String>> {
66        self.tags.as_ref()
67    }
68    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see <a href="https://aws.amazon.com/builders-library/making-retries-safe-with-idempotent-APIs/">Making retries safe with idempotent APIs</a>.</p>
69    pub fn client_token(&self) -> ::std::option::Option<&str> {
70        self.client_token.as_deref()
71    }
72    /// <p>The configuration for what files should be pulled from the source.</p>
73    pub fn file_configuration(&self) -> ::std::option::Option<&crate::types::FileConfiguration> {
74        self.file_configuration.as_ref()
75    }
76    /// <p>The configuration for what data should be pulled from the source.</p>
77    pub fn object_configuration(
78        &self,
79    ) -> ::std::option::Option<
80        &::std::collections::HashMap<
81            ::std::string::String,
82            ::std::collections::HashMap<::std::string::String, ::std::vec::Vec<::std::string::String>>,
83        >,
84    > {
85        self.object_configuration.as_ref()
86    }
87}
88impl ::aws_types::request_id::RequestId for CreateDataIntegrationOutput {
89    fn request_id(&self) -> Option<&str> {
90        self._request_id.as_deref()
91    }
92}
93impl CreateDataIntegrationOutput {
94    /// Creates a new builder-style object to manufacture [`CreateDataIntegrationOutput`](crate::operation::create_data_integration::CreateDataIntegrationOutput).
95    pub fn builder() -> crate::operation::create_data_integration::builders::CreateDataIntegrationOutputBuilder {
96        crate::operation::create_data_integration::builders::CreateDataIntegrationOutputBuilder::default()
97    }
98}
99
100/// A builder for [`CreateDataIntegrationOutput`](crate::operation::create_data_integration::CreateDataIntegrationOutput).
101#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
102#[non_exhaustive]
103pub struct CreateDataIntegrationOutputBuilder {
104    pub(crate) arn: ::std::option::Option<::std::string::String>,
105    pub(crate) id: ::std::option::Option<::std::string::String>,
106    pub(crate) name: ::std::option::Option<::std::string::String>,
107    pub(crate) description: ::std::option::Option<::std::string::String>,
108    pub(crate) kms_key: ::std::option::Option<::std::string::String>,
109    pub(crate) source_uri: ::std::option::Option<::std::string::String>,
110    pub(crate) schedule_configuration: ::std::option::Option<crate::types::ScheduleConfiguration>,
111    pub(crate) tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
112    pub(crate) client_token: ::std::option::Option<::std::string::String>,
113    pub(crate) file_configuration: ::std::option::Option<crate::types::FileConfiguration>,
114    pub(crate) object_configuration: ::std::option::Option<
115        ::std::collections::HashMap<
116            ::std::string::String,
117            ::std::collections::HashMap<::std::string::String, ::std::vec::Vec<::std::string::String>>,
118        >,
119    >,
120    _request_id: Option<String>,
121}
122impl CreateDataIntegrationOutputBuilder {
123    /// <p>The Amazon Resource Name (ARN)</p>
124    pub fn arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
125        self.arn = ::std::option::Option::Some(input.into());
126        self
127    }
128    /// <p>The Amazon Resource Name (ARN)</p>
129    pub fn set_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
130        self.arn = input;
131        self
132    }
133    /// <p>The Amazon Resource Name (ARN)</p>
134    pub fn get_arn(&self) -> &::std::option::Option<::std::string::String> {
135        &self.arn
136    }
137    /// <p>A unique identifier.</p>
138    pub fn id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
139        self.id = ::std::option::Option::Some(input.into());
140        self
141    }
142    /// <p>A unique identifier.</p>
143    pub fn set_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
144        self.id = input;
145        self
146    }
147    /// <p>A unique identifier.</p>
148    pub fn get_id(&self) -> &::std::option::Option<::std::string::String> {
149        &self.id
150    }
151    /// <p>The name of the DataIntegration.</p>
152    pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
153        self.name = ::std::option::Option::Some(input.into());
154        self
155    }
156    /// <p>The name of the DataIntegration.</p>
157    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
158        self.name = input;
159        self
160    }
161    /// <p>The name of the DataIntegration.</p>
162    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
163        &self.name
164    }
165    /// <p>A description of the DataIntegration.</p>
166    pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
167        self.description = ::std::option::Option::Some(input.into());
168        self
169    }
170    /// <p>A description of the DataIntegration.</p>
171    pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
172        self.description = input;
173        self
174    }
175    /// <p>A description of the DataIntegration.</p>
176    pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
177        &self.description
178    }
179    /// <p>The KMS key ARN for the DataIntegration.</p>
180    pub fn kms_key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
181        self.kms_key = ::std::option::Option::Some(input.into());
182        self
183    }
184    /// <p>The KMS key ARN for the DataIntegration.</p>
185    pub fn set_kms_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
186        self.kms_key = input;
187        self
188    }
189    /// <p>The KMS key ARN for the DataIntegration.</p>
190    pub fn get_kms_key(&self) -> &::std::option::Option<::std::string::String> {
191        &self.kms_key
192    }
193    /// <p>The URI of the data source.</p>
194    pub fn source_uri(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
195        self.source_uri = ::std::option::Option::Some(input.into());
196        self
197    }
198    /// <p>The URI of the data source.</p>
199    pub fn set_source_uri(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
200        self.source_uri = input;
201        self
202    }
203    /// <p>The URI of the data source.</p>
204    pub fn get_source_uri(&self) -> &::std::option::Option<::std::string::String> {
205        &self.source_uri
206    }
207    /// <p>The name of the data and how often it should be pulled from the source.</p>
208    pub fn schedule_configuration(mut self, input: crate::types::ScheduleConfiguration) -> Self {
209        self.schedule_configuration = ::std::option::Option::Some(input);
210        self
211    }
212    /// <p>The name of the data and how often it should be pulled from the source.</p>
213    pub fn set_schedule_configuration(mut self, input: ::std::option::Option<crate::types::ScheduleConfiguration>) -> Self {
214        self.schedule_configuration = input;
215        self
216    }
217    /// <p>The name of the data and how often it should be pulled from the source.</p>
218    pub fn get_schedule_configuration(&self) -> &::std::option::Option<crate::types::ScheduleConfiguration> {
219        &self.schedule_configuration
220    }
221    /// Adds a key-value pair to `tags`.
222    ///
223    /// To override the contents of this collection use [`set_tags`](Self::set_tags).
224    ///
225    /// <p>The tags used to organize, track, or control access for this resource. For example, { "tags": {"key1":"value1", "key2":"value2"} }.</p>
226    pub fn tags(mut self, k: impl ::std::convert::Into<::std::string::String>, v: impl ::std::convert::Into<::std::string::String>) -> Self {
227        let mut hash_map = self.tags.unwrap_or_default();
228        hash_map.insert(k.into(), v.into());
229        self.tags = ::std::option::Option::Some(hash_map);
230        self
231    }
232    /// <p>The tags used to organize, track, or control access for this resource. For example, { "tags": {"key1":"value1", "key2":"value2"} }.</p>
233    pub fn set_tags(mut self, input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>) -> Self {
234        self.tags = input;
235        self
236    }
237    /// <p>The tags used to organize, track, or control access for this resource. For example, { "tags": {"key1":"value1", "key2":"value2"} }.</p>
238    pub fn get_tags(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
239        &self.tags
240    }
241    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see <a href="https://aws.amazon.com/builders-library/making-retries-safe-with-idempotent-APIs/">Making retries safe with idempotent APIs</a>.</p>
242    pub fn client_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
243        self.client_token = ::std::option::Option::Some(input.into());
244        self
245    }
246    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see <a href="https://aws.amazon.com/builders-library/making-retries-safe-with-idempotent-APIs/">Making retries safe with idempotent APIs</a>.</p>
247    pub fn set_client_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
248        self.client_token = input;
249        self
250    }
251    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see <a href="https://aws.amazon.com/builders-library/making-retries-safe-with-idempotent-APIs/">Making retries safe with idempotent APIs</a>.</p>
252    pub fn get_client_token(&self) -> &::std::option::Option<::std::string::String> {
253        &self.client_token
254    }
255    /// <p>The configuration for what files should be pulled from the source.</p>
256    pub fn file_configuration(mut self, input: crate::types::FileConfiguration) -> Self {
257        self.file_configuration = ::std::option::Option::Some(input);
258        self
259    }
260    /// <p>The configuration for what files should be pulled from the source.</p>
261    pub fn set_file_configuration(mut self, input: ::std::option::Option<crate::types::FileConfiguration>) -> Self {
262        self.file_configuration = input;
263        self
264    }
265    /// <p>The configuration for what files should be pulled from the source.</p>
266    pub fn get_file_configuration(&self) -> &::std::option::Option<crate::types::FileConfiguration> {
267        &self.file_configuration
268    }
269    /// Adds a key-value pair to `object_configuration`.
270    ///
271    /// To override the contents of this collection use [`set_object_configuration`](Self::set_object_configuration).
272    ///
273    /// <p>The configuration for what data should be pulled from the source.</p>
274    pub fn object_configuration(
275        mut self,
276        k: impl ::std::convert::Into<::std::string::String>,
277        v: ::std::collections::HashMap<::std::string::String, ::std::vec::Vec<::std::string::String>>,
278    ) -> Self {
279        let mut hash_map = self.object_configuration.unwrap_or_default();
280        hash_map.insert(k.into(), v);
281        self.object_configuration = ::std::option::Option::Some(hash_map);
282        self
283    }
284    /// <p>The configuration for what data should be pulled from the source.</p>
285    pub fn set_object_configuration(
286        mut self,
287        input: ::std::option::Option<
288            ::std::collections::HashMap<
289                ::std::string::String,
290                ::std::collections::HashMap<::std::string::String, ::std::vec::Vec<::std::string::String>>,
291            >,
292        >,
293    ) -> Self {
294        self.object_configuration = input;
295        self
296    }
297    /// <p>The configuration for what data should be pulled from the source.</p>
298    pub fn get_object_configuration(
299        &self,
300    ) -> &::std::option::Option<
301        ::std::collections::HashMap<
302            ::std::string::String,
303            ::std::collections::HashMap<::std::string::String, ::std::vec::Vec<::std::string::String>>,
304        >,
305    > {
306        &self.object_configuration
307    }
308    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
309        self._request_id = Some(request_id.into());
310        self
311    }
312
313    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
314        self._request_id = request_id;
315        self
316    }
317    /// Consumes the builder and constructs a [`CreateDataIntegrationOutput`](crate::operation::create_data_integration::CreateDataIntegrationOutput).
318    pub fn build(self) -> crate::operation::create_data_integration::CreateDataIntegrationOutput {
319        crate::operation::create_data_integration::CreateDataIntegrationOutput {
320            arn: self.arn,
321            id: self.id,
322            name: self.name,
323            description: self.description,
324            kms_key: self.kms_key,
325            source_uri: self.source_uri,
326            schedule_configuration: self.schedule_configuration,
327            tags: self.tags,
328            client_token: self.client_token,
329            file_configuration: self.file_configuration,
330            object_configuration: self.object_configuration,
331            _request_id: self._request_id,
332        }
333    }
334}