aws_sdk_machinelearning/operation/get_data_source/
_get_data_source_output.rs

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
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// <p>Represents the output of a <code>GetDataSource</code> operation and describes a <code>DataSource</code>.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct GetDataSourceOutput {
    /// <p>The ID assigned to the <code>DataSource</code> at creation. This value should be identical to the value of the <code>DataSourceId</code> in the request.</p>
    pub data_source_id: ::std::option::Option<::std::string::String>,
    /// <p>The location of the data file or directory in Amazon Simple Storage Service (Amazon S3).</p>
    pub data_location_s3: ::std::option::Option<::std::string::String>,
    /// <p>A JSON string that represents the splitting and rearrangement requirement used when this <code>DataSource</code> was created.</p>
    pub data_rearrangement: ::std::option::Option<::std::string::String>,
    /// <p>The AWS user account from which the <code>DataSource</code> was created. The account type can be either an AWS root account or an AWS Identity and Access Management (IAM) user account.</p>
    pub created_by_iam_user: ::std::option::Option<::std::string::String>,
    /// <p>The time that the <code>DataSource</code> was created. The time is expressed in epoch time.</p>
    pub created_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    /// <p>The time of the most recent edit to the <code>DataSource</code>. The time is expressed in epoch time.</p>
    pub last_updated_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    /// <p>The total size of observations in the data files.</p>
    pub data_size_in_bytes: ::std::option::Option<i64>,
    /// <p>The number of data files referenced by the <code>DataSource</code>.</p>
    pub number_of_files: ::std::option::Option<i64>,
    /// <p>A user-supplied name or description of the <code>DataSource</code>.</p>
    pub name: ::std::option::Option<::std::string::String>,
    /// <p>The current status of the <code>DataSource</code>. This element can have one of the following values:</p>
    /// <ul>
    /// <li>
    /// <p><code>PENDING</code> - Amazon ML submitted a request to create a <code>DataSource</code>.</p></li>
    /// <li>
    /// <p><code>INPROGRESS</code> - The creation process is underway.</p></li>
    /// <li>
    /// <p><code>FAILED</code> - The request to create a <code>DataSource</code> did not run to completion. It is not usable.</p></li>
    /// <li>
    /// <p><code>COMPLETED</code> - The creation process completed successfully.</p></li>
    /// <li>
    /// <p><code>DELETED</code> - The <code>DataSource</code> is marked as deleted. It is not usable.</p></li>
    /// </ul>
    pub status: ::std::option::Option<crate::types::EntityStatus>,
    /// <p>A link to the file containing logs of <code>CreateDataSourceFrom*</code> operations.</p>
    pub log_uri: ::std::option::Option<::std::string::String>,
    /// <p>The user-supplied description of the most recent details about creating the <code>DataSource</code>.</p>
    pub message: ::std::option::Option<::std::string::String>,
    /// <p>Describes the <code>DataSource</code> details specific to Amazon Redshift.</p>
    pub redshift_metadata: ::std::option::Option<crate::types::RedshiftMetadata>,
    /// <p>The datasource details that are specific to Amazon RDS.</p>
    pub rds_metadata: ::std::option::Option<crate::types::RdsMetadata>,
    /// <p>The Amazon Resource Name (ARN) of an <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/roles-toplevel.html#roles-about-termsandconcepts">AWS IAM Role</a>, such as the following: arn:aws:iam::account:role/rolename.</p>
    pub role_arn: ::std::option::Option<::std::string::String>,
    /// <p>The parameter is <code>true</code> if statistics need to be generated from the observation data.</p>
    pub compute_statistics: bool,
    /// <p>The approximate CPU time in milliseconds that Amazon Machine Learning spent processing the <code>DataSource</code>, normalized and scaled on computation resources. <code>ComputeTime</code> is only available if the <code>DataSource</code> is in the <code>COMPLETED</code> state and the <code>ComputeStatistics</code> is set to true.</p>
    pub compute_time: ::std::option::Option<i64>,
    /// <p>The epoch time when Amazon Machine Learning marked the <code>DataSource</code> as <code>COMPLETED</code> or <code>FAILED</code>. <code>FinishedAt</code> is only available when the <code>DataSource</code> is in the <code>COMPLETED</code> or <code>FAILED</code> state.</p>
    pub finished_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    /// <p>The epoch time when Amazon Machine Learning marked the <code>DataSource</code> as <code>INPROGRESS</code>. <code>StartedAt</code> isn't available if the <code>DataSource</code> is in the <code>PENDING</code> state.</p>
    pub started_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    /// <p>The schema used by all of the data files of this <code>DataSource</code>.</p>
    /// <p><b>Note:</b> This parameter is provided as part of the verbose format.</p>
    pub data_source_schema: ::std::option::Option<::std::string::String>,
    _request_id: Option<String>,
}
impl GetDataSourceOutput {
    /// <p>The ID assigned to the <code>DataSource</code> at creation. This value should be identical to the value of the <code>DataSourceId</code> in the request.</p>
    pub fn data_source_id(&self) -> ::std::option::Option<&str> {
        self.data_source_id.as_deref()
    }
    /// <p>The location of the data file or directory in Amazon Simple Storage Service (Amazon S3).</p>
    pub fn data_location_s3(&self) -> ::std::option::Option<&str> {
        self.data_location_s3.as_deref()
    }
    /// <p>A JSON string that represents the splitting and rearrangement requirement used when this <code>DataSource</code> was created.</p>
    pub fn data_rearrangement(&self) -> ::std::option::Option<&str> {
        self.data_rearrangement.as_deref()
    }
    /// <p>The AWS user account from which the <code>DataSource</code> was created. The account type can be either an AWS root account or an AWS Identity and Access Management (IAM) user account.</p>
    pub fn created_by_iam_user(&self) -> ::std::option::Option<&str> {
        self.created_by_iam_user.as_deref()
    }
    /// <p>The time that the <code>DataSource</code> was created. The time is expressed in epoch time.</p>
    pub fn created_at(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.created_at.as_ref()
    }
    /// <p>The time of the most recent edit to the <code>DataSource</code>. The time is expressed in epoch time.</p>
    pub fn last_updated_at(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.last_updated_at.as_ref()
    }
    /// <p>The total size of observations in the data files.</p>
    pub fn data_size_in_bytes(&self) -> ::std::option::Option<i64> {
        self.data_size_in_bytes
    }
    /// <p>The number of data files referenced by the <code>DataSource</code>.</p>
    pub fn number_of_files(&self) -> ::std::option::Option<i64> {
        self.number_of_files
    }
    /// <p>A user-supplied name or description of the <code>DataSource</code>.</p>
    pub fn name(&self) -> ::std::option::Option<&str> {
        self.name.as_deref()
    }
    /// <p>The current status of the <code>DataSource</code>. This element can have one of the following values:</p>
    /// <ul>
    /// <li>
    /// <p><code>PENDING</code> - Amazon ML submitted a request to create a <code>DataSource</code>.</p></li>
    /// <li>
    /// <p><code>INPROGRESS</code> - The creation process is underway.</p></li>
    /// <li>
    /// <p><code>FAILED</code> - The request to create a <code>DataSource</code> did not run to completion. It is not usable.</p></li>
    /// <li>
    /// <p><code>COMPLETED</code> - The creation process completed successfully.</p></li>
    /// <li>
    /// <p><code>DELETED</code> - The <code>DataSource</code> is marked as deleted. It is not usable.</p></li>
    /// </ul>
    pub fn status(&self) -> ::std::option::Option<&crate::types::EntityStatus> {
        self.status.as_ref()
    }
    /// <p>A link to the file containing logs of <code>CreateDataSourceFrom*</code> operations.</p>
    pub fn log_uri(&self) -> ::std::option::Option<&str> {
        self.log_uri.as_deref()
    }
    /// <p>The user-supplied description of the most recent details about creating the <code>DataSource</code>.</p>
    pub fn message(&self) -> ::std::option::Option<&str> {
        self.message.as_deref()
    }
    /// <p>Describes the <code>DataSource</code> details specific to Amazon Redshift.</p>
    pub fn redshift_metadata(&self) -> ::std::option::Option<&crate::types::RedshiftMetadata> {
        self.redshift_metadata.as_ref()
    }
    /// <p>The datasource details that are specific to Amazon RDS.</p>
    pub fn rds_metadata(&self) -> ::std::option::Option<&crate::types::RdsMetadata> {
        self.rds_metadata.as_ref()
    }
    /// <p>The Amazon Resource Name (ARN) of an <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/roles-toplevel.html#roles-about-termsandconcepts">AWS IAM Role</a>, such as the following: arn:aws:iam::account:role/rolename.</p>
    pub fn role_arn(&self) -> ::std::option::Option<&str> {
        self.role_arn.as_deref()
    }
    /// <p>The parameter is <code>true</code> if statistics need to be generated from the observation data.</p>
    pub fn compute_statistics(&self) -> bool {
        self.compute_statistics
    }
    /// <p>The approximate CPU time in milliseconds that Amazon Machine Learning spent processing the <code>DataSource</code>, normalized and scaled on computation resources. <code>ComputeTime</code> is only available if the <code>DataSource</code> is in the <code>COMPLETED</code> state and the <code>ComputeStatistics</code> is set to true.</p>
    pub fn compute_time(&self) -> ::std::option::Option<i64> {
        self.compute_time
    }
    /// <p>The epoch time when Amazon Machine Learning marked the <code>DataSource</code> as <code>COMPLETED</code> or <code>FAILED</code>. <code>FinishedAt</code> is only available when the <code>DataSource</code> is in the <code>COMPLETED</code> or <code>FAILED</code> state.</p>
    pub fn finished_at(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.finished_at.as_ref()
    }
    /// <p>The epoch time when Amazon Machine Learning marked the <code>DataSource</code> as <code>INPROGRESS</code>. <code>StartedAt</code> isn't available if the <code>DataSource</code> is in the <code>PENDING</code> state.</p>
    pub fn started_at(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.started_at.as_ref()
    }
    /// <p>The schema used by all of the data files of this <code>DataSource</code>.</p>
    /// <p><b>Note:</b> This parameter is provided as part of the verbose format.</p>
    pub fn data_source_schema(&self) -> ::std::option::Option<&str> {
        self.data_source_schema.as_deref()
    }
}
impl ::aws_types::request_id::RequestId for GetDataSourceOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl GetDataSourceOutput {
    /// Creates a new builder-style object to manufacture [`GetDataSourceOutput`](crate::operation::get_data_source::GetDataSourceOutput).
    pub fn builder() -> crate::operation::get_data_source::builders::GetDataSourceOutputBuilder {
        crate::operation::get_data_source::builders::GetDataSourceOutputBuilder::default()
    }
}

/// A builder for [`GetDataSourceOutput`](crate::operation::get_data_source::GetDataSourceOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetDataSourceOutputBuilder {
    pub(crate) data_source_id: ::std::option::Option<::std::string::String>,
    pub(crate) data_location_s3: ::std::option::Option<::std::string::String>,
    pub(crate) data_rearrangement: ::std::option::Option<::std::string::String>,
    pub(crate) created_by_iam_user: ::std::option::Option<::std::string::String>,
    pub(crate) created_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    pub(crate) last_updated_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    pub(crate) data_size_in_bytes: ::std::option::Option<i64>,
    pub(crate) number_of_files: ::std::option::Option<i64>,
    pub(crate) name: ::std::option::Option<::std::string::String>,
    pub(crate) status: ::std::option::Option<crate::types::EntityStatus>,
    pub(crate) log_uri: ::std::option::Option<::std::string::String>,
    pub(crate) message: ::std::option::Option<::std::string::String>,
    pub(crate) redshift_metadata: ::std::option::Option<crate::types::RedshiftMetadata>,
    pub(crate) rds_metadata: ::std::option::Option<crate::types::RdsMetadata>,
    pub(crate) role_arn: ::std::option::Option<::std::string::String>,
    pub(crate) compute_statistics: ::std::option::Option<bool>,
    pub(crate) compute_time: ::std::option::Option<i64>,
    pub(crate) finished_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    pub(crate) started_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    pub(crate) data_source_schema: ::std::option::Option<::std::string::String>,
    _request_id: Option<String>,
}
impl GetDataSourceOutputBuilder {
    /// <p>The ID assigned to the <code>DataSource</code> at creation. This value should be identical to the value of the <code>DataSourceId</code> in the request.</p>
    pub fn data_source_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.data_source_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID assigned to the <code>DataSource</code> at creation. This value should be identical to the value of the <code>DataSourceId</code> in the request.</p>
    pub fn set_data_source_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.data_source_id = input;
        self
    }
    /// <p>The ID assigned to the <code>DataSource</code> at creation. This value should be identical to the value of the <code>DataSourceId</code> in the request.</p>
    pub fn get_data_source_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.data_source_id
    }
    /// <p>The location of the data file or directory in Amazon Simple Storage Service (Amazon S3).</p>
    pub fn data_location_s3(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.data_location_s3 = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The location of the data file or directory in Amazon Simple Storage Service (Amazon S3).</p>
    pub fn set_data_location_s3(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.data_location_s3 = input;
        self
    }
    /// <p>The location of the data file or directory in Amazon Simple Storage Service (Amazon S3).</p>
    pub fn get_data_location_s3(&self) -> &::std::option::Option<::std::string::String> {
        &self.data_location_s3
    }
    /// <p>A JSON string that represents the splitting and rearrangement requirement used when this <code>DataSource</code> was created.</p>
    pub fn data_rearrangement(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.data_rearrangement = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>A JSON string that represents the splitting and rearrangement requirement used when this <code>DataSource</code> was created.</p>
    pub fn set_data_rearrangement(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.data_rearrangement = input;
        self
    }
    /// <p>A JSON string that represents the splitting and rearrangement requirement used when this <code>DataSource</code> was created.</p>
    pub fn get_data_rearrangement(&self) -> &::std::option::Option<::std::string::String> {
        &self.data_rearrangement
    }
    /// <p>The AWS user account from which the <code>DataSource</code> was created. The account type can be either an AWS root account or an AWS Identity and Access Management (IAM) user account.</p>
    pub fn created_by_iam_user(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.created_by_iam_user = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The AWS user account from which the <code>DataSource</code> was created. The account type can be either an AWS root account or an AWS Identity and Access Management (IAM) user account.</p>
    pub fn set_created_by_iam_user(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.created_by_iam_user = input;
        self
    }
    /// <p>The AWS user account from which the <code>DataSource</code> was created. The account type can be either an AWS root account or an AWS Identity and Access Management (IAM) user account.</p>
    pub fn get_created_by_iam_user(&self) -> &::std::option::Option<::std::string::String> {
        &self.created_by_iam_user
    }
    /// <p>The time that the <code>DataSource</code> was created. The time is expressed in epoch time.</p>
    pub fn created_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.created_at = ::std::option::Option::Some(input);
        self
    }
    /// <p>The time that the <code>DataSource</code> was created. The time is expressed in epoch time.</p>
    pub fn set_created_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.created_at = input;
        self
    }
    /// <p>The time that the <code>DataSource</code> was created. The time is expressed in epoch time.</p>
    pub fn get_created_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.created_at
    }
    /// <p>The time of the most recent edit to the <code>DataSource</code>. The time is expressed in epoch time.</p>
    pub fn last_updated_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.last_updated_at = ::std::option::Option::Some(input);
        self
    }
    /// <p>The time of the most recent edit to the <code>DataSource</code>. The time is expressed in epoch time.</p>
    pub fn set_last_updated_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.last_updated_at = input;
        self
    }
    /// <p>The time of the most recent edit to the <code>DataSource</code>. The time is expressed in epoch time.</p>
    pub fn get_last_updated_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.last_updated_at
    }
    /// <p>The total size of observations in the data files.</p>
    pub fn data_size_in_bytes(mut self, input: i64) -> Self {
        self.data_size_in_bytes = ::std::option::Option::Some(input);
        self
    }
    /// <p>The total size of observations in the data files.</p>
    pub fn set_data_size_in_bytes(mut self, input: ::std::option::Option<i64>) -> Self {
        self.data_size_in_bytes = input;
        self
    }
    /// <p>The total size of observations in the data files.</p>
    pub fn get_data_size_in_bytes(&self) -> &::std::option::Option<i64> {
        &self.data_size_in_bytes
    }
    /// <p>The number of data files referenced by the <code>DataSource</code>.</p>
    pub fn number_of_files(mut self, input: i64) -> Self {
        self.number_of_files = ::std::option::Option::Some(input);
        self
    }
    /// <p>The number of data files referenced by the <code>DataSource</code>.</p>
    pub fn set_number_of_files(mut self, input: ::std::option::Option<i64>) -> Self {
        self.number_of_files = input;
        self
    }
    /// <p>The number of data files referenced by the <code>DataSource</code>.</p>
    pub fn get_number_of_files(&self) -> &::std::option::Option<i64> {
        &self.number_of_files
    }
    /// <p>A user-supplied name or description of the <code>DataSource</code>.</p>
    pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>A user-supplied name or description of the <code>DataSource</code>.</p>
    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.name = input;
        self
    }
    /// <p>A user-supplied name or description of the <code>DataSource</code>.</p>
    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.name
    }
    /// <p>The current status of the <code>DataSource</code>. This element can have one of the following values:</p>
    /// <ul>
    /// <li>
    /// <p><code>PENDING</code> - Amazon ML submitted a request to create a <code>DataSource</code>.</p></li>
    /// <li>
    /// <p><code>INPROGRESS</code> - The creation process is underway.</p></li>
    /// <li>
    /// <p><code>FAILED</code> - The request to create a <code>DataSource</code> did not run to completion. It is not usable.</p></li>
    /// <li>
    /// <p><code>COMPLETED</code> - The creation process completed successfully.</p></li>
    /// <li>
    /// <p><code>DELETED</code> - The <code>DataSource</code> is marked as deleted. It is not usable.</p></li>
    /// </ul>
    pub fn status(mut self, input: crate::types::EntityStatus) -> Self {
        self.status = ::std::option::Option::Some(input);
        self
    }
    /// <p>The current status of the <code>DataSource</code>. This element can have one of the following values:</p>
    /// <ul>
    /// <li>
    /// <p><code>PENDING</code> - Amazon ML submitted a request to create a <code>DataSource</code>.</p></li>
    /// <li>
    /// <p><code>INPROGRESS</code> - The creation process is underway.</p></li>
    /// <li>
    /// <p><code>FAILED</code> - The request to create a <code>DataSource</code> did not run to completion. It is not usable.</p></li>
    /// <li>
    /// <p><code>COMPLETED</code> - The creation process completed successfully.</p></li>
    /// <li>
    /// <p><code>DELETED</code> - The <code>DataSource</code> is marked as deleted. It is not usable.</p></li>
    /// </ul>
    pub fn set_status(mut self, input: ::std::option::Option<crate::types::EntityStatus>) -> Self {
        self.status = input;
        self
    }
    /// <p>The current status of the <code>DataSource</code>. This element can have one of the following values:</p>
    /// <ul>
    /// <li>
    /// <p><code>PENDING</code> - Amazon ML submitted a request to create a <code>DataSource</code>.</p></li>
    /// <li>
    /// <p><code>INPROGRESS</code> - The creation process is underway.</p></li>
    /// <li>
    /// <p><code>FAILED</code> - The request to create a <code>DataSource</code> did not run to completion. It is not usable.</p></li>
    /// <li>
    /// <p><code>COMPLETED</code> - The creation process completed successfully.</p></li>
    /// <li>
    /// <p><code>DELETED</code> - The <code>DataSource</code> is marked as deleted. It is not usable.</p></li>
    /// </ul>
    pub fn get_status(&self) -> &::std::option::Option<crate::types::EntityStatus> {
        &self.status
    }
    /// <p>A link to the file containing logs of <code>CreateDataSourceFrom*</code> operations.</p>
    pub fn log_uri(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.log_uri = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>A link to the file containing logs of <code>CreateDataSourceFrom*</code> operations.</p>
    pub fn set_log_uri(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.log_uri = input;
        self
    }
    /// <p>A link to the file containing logs of <code>CreateDataSourceFrom*</code> operations.</p>
    pub fn get_log_uri(&self) -> &::std::option::Option<::std::string::String> {
        &self.log_uri
    }
    /// <p>The user-supplied description of the most recent details about creating the <code>DataSource</code>.</p>
    pub fn message(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.message = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The user-supplied description of the most recent details about creating the <code>DataSource</code>.</p>
    pub fn set_message(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.message = input;
        self
    }
    /// <p>The user-supplied description of the most recent details about creating the <code>DataSource</code>.</p>
    pub fn get_message(&self) -> &::std::option::Option<::std::string::String> {
        &self.message
    }
    /// <p>Describes the <code>DataSource</code> details specific to Amazon Redshift.</p>
    pub fn redshift_metadata(mut self, input: crate::types::RedshiftMetadata) -> Self {
        self.redshift_metadata = ::std::option::Option::Some(input);
        self
    }
    /// <p>Describes the <code>DataSource</code> details specific to Amazon Redshift.</p>
    pub fn set_redshift_metadata(mut self, input: ::std::option::Option<crate::types::RedshiftMetadata>) -> Self {
        self.redshift_metadata = input;
        self
    }
    /// <p>Describes the <code>DataSource</code> details specific to Amazon Redshift.</p>
    pub fn get_redshift_metadata(&self) -> &::std::option::Option<crate::types::RedshiftMetadata> {
        &self.redshift_metadata
    }
    /// <p>The datasource details that are specific to Amazon RDS.</p>
    pub fn rds_metadata(mut self, input: crate::types::RdsMetadata) -> Self {
        self.rds_metadata = ::std::option::Option::Some(input);
        self
    }
    /// <p>The datasource details that are specific to Amazon RDS.</p>
    pub fn set_rds_metadata(mut self, input: ::std::option::Option<crate::types::RdsMetadata>) -> Self {
        self.rds_metadata = input;
        self
    }
    /// <p>The datasource details that are specific to Amazon RDS.</p>
    pub fn get_rds_metadata(&self) -> &::std::option::Option<crate::types::RdsMetadata> {
        &self.rds_metadata
    }
    /// <p>The Amazon Resource Name (ARN) of an <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/roles-toplevel.html#roles-about-termsandconcepts">AWS IAM Role</a>, such as the following: arn:aws:iam::account:role/rolename.</p>
    pub fn role_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.role_arn = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The Amazon Resource Name (ARN) of an <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/roles-toplevel.html#roles-about-termsandconcepts">AWS IAM Role</a>, such as the following: arn:aws:iam::account:role/rolename.</p>
    pub fn set_role_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.role_arn = input;
        self
    }
    /// <p>The Amazon Resource Name (ARN) of an <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/roles-toplevel.html#roles-about-termsandconcepts">AWS IAM Role</a>, such as the following: arn:aws:iam::account:role/rolename.</p>
    pub fn get_role_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.role_arn
    }
    /// <p>The parameter is <code>true</code> if statistics need to be generated from the observation data.</p>
    pub fn compute_statistics(mut self, input: bool) -> Self {
        self.compute_statistics = ::std::option::Option::Some(input);
        self
    }
    /// <p>The parameter is <code>true</code> if statistics need to be generated from the observation data.</p>
    pub fn set_compute_statistics(mut self, input: ::std::option::Option<bool>) -> Self {
        self.compute_statistics = input;
        self
    }
    /// <p>The parameter is <code>true</code> if statistics need to be generated from the observation data.</p>
    pub fn get_compute_statistics(&self) -> &::std::option::Option<bool> {
        &self.compute_statistics
    }
    /// <p>The approximate CPU time in milliseconds that Amazon Machine Learning spent processing the <code>DataSource</code>, normalized and scaled on computation resources. <code>ComputeTime</code> is only available if the <code>DataSource</code> is in the <code>COMPLETED</code> state and the <code>ComputeStatistics</code> is set to true.</p>
    pub fn compute_time(mut self, input: i64) -> Self {
        self.compute_time = ::std::option::Option::Some(input);
        self
    }
    /// <p>The approximate CPU time in milliseconds that Amazon Machine Learning spent processing the <code>DataSource</code>, normalized and scaled on computation resources. <code>ComputeTime</code> is only available if the <code>DataSource</code> is in the <code>COMPLETED</code> state and the <code>ComputeStatistics</code> is set to true.</p>
    pub fn set_compute_time(mut self, input: ::std::option::Option<i64>) -> Self {
        self.compute_time = input;
        self
    }
    /// <p>The approximate CPU time in milliseconds that Amazon Machine Learning spent processing the <code>DataSource</code>, normalized and scaled on computation resources. <code>ComputeTime</code> is only available if the <code>DataSource</code> is in the <code>COMPLETED</code> state and the <code>ComputeStatistics</code> is set to true.</p>
    pub fn get_compute_time(&self) -> &::std::option::Option<i64> {
        &self.compute_time
    }
    /// <p>The epoch time when Amazon Machine Learning marked the <code>DataSource</code> as <code>COMPLETED</code> or <code>FAILED</code>. <code>FinishedAt</code> is only available when the <code>DataSource</code> is in the <code>COMPLETED</code> or <code>FAILED</code> state.</p>
    pub fn finished_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.finished_at = ::std::option::Option::Some(input);
        self
    }
    /// <p>The epoch time when Amazon Machine Learning marked the <code>DataSource</code> as <code>COMPLETED</code> or <code>FAILED</code>. <code>FinishedAt</code> is only available when the <code>DataSource</code> is in the <code>COMPLETED</code> or <code>FAILED</code> state.</p>
    pub fn set_finished_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.finished_at = input;
        self
    }
    /// <p>The epoch time when Amazon Machine Learning marked the <code>DataSource</code> as <code>COMPLETED</code> or <code>FAILED</code>. <code>FinishedAt</code> is only available when the <code>DataSource</code> is in the <code>COMPLETED</code> or <code>FAILED</code> state.</p>
    pub fn get_finished_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.finished_at
    }
    /// <p>The epoch time when Amazon Machine Learning marked the <code>DataSource</code> as <code>INPROGRESS</code>. <code>StartedAt</code> isn't available if the <code>DataSource</code> is in the <code>PENDING</code> state.</p>
    pub fn started_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.started_at = ::std::option::Option::Some(input);
        self
    }
    /// <p>The epoch time when Amazon Machine Learning marked the <code>DataSource</code> as <code>INPROGRESS</code>. <code>StartedAt</code> isn't available if the <code>DataSource</code> is in the <code>PENDING</code> state.</p>
    pub fn set_started_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.started_at = input;
        self
    }
    /// <p>The epoch time when Amazon Machine Learning marked the <code>DataSource</code> as <code>INPROGRESS</code>. <code>StartedAt</code> isn't available if the <code>DataSource</code> is in the <code>PENDING</code> state.</p>
    pub fn get_started_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.started_at
    }
    /// <p>The schema used by all of the data files of this <code>DataSource</code>.</p>
    /// <p><b>Note:</b> This parameter is provided as part of the verbose format.</p>
    pub fn data_source_schema(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.data_source_schema = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The schema used by all of the data files of this <code>DataSource</code>.</p>
    /// <p><b>Note:</b> This parameter is provided as part of the verbose format.</p>
    pub fn set_data_source_schema(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.data_source_schema = input;
        self
    }
    /// <p>The schema used by all of the data files of this <code>DataSource</code>.</p>
    /// <p><b>Note:</b> This parameter is provided as part of the verbose format.</p>
    pub fn get_data_source_schema(&self) -> &::std::option::Option<::std::string::String> {
        &self.data_source_schema
    }
    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
        self._request_id = Some(request_id.into());
        self
    }

    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
        self._request_id = request_id;
        self
    }
    /// Consumes the builder and constructs a [`GetDataSourceOutput`](crate::operation::get_data_source::GetDataSourceOutput).
    pub fn build(self) -> crate::operation::get_data_source::GetDataSourceOutput {
        crate::operation::get_data_source::GetDataSourceOutput {
            data_source_id: self.data_source_id,
            data_location_s3: self.data_location_s3,
            data_rearrangement: self.data_rearrangement,
            created_by_iam_user: self.created_by_iam_user,
            created_at: self.created_at,
            last_updated_at: self.last_updated_at,
            data_size_in_bytes: self.data_size_in_bytes,
            number_of_files: self.number_of_files,
            name: self.name,
            status: self.status,
            log_uri: self.log_uri,
            message: self.message,
            redshift_metadata: self.redshift_metadata,
            rds_metadata: self.rds_metadata,
            role_arn: self.role_arn,
            compute_statistics: self.compute_statistics.unwrap_or_default(),
            compute_time: self.compute_time,
            finished_at: self.finished_at,
            started_at: self.started_at,
            data_source_schema: self.data_source_schema,
            _request_id: self._request_id,
        }
    }
}