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
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct StartScanJobInput {
/// <p>The name of a logical container where backups are stored. Backup vaults are identified by names that are unique to the account used to create them and the Amazon Web Services Region where they are created.</p>
/// <p>Pattern: <code>^\[a-zA-Z0-9\-\_\]{2,50}$</code></p>
pub backup_vault_name: ::std::option::Option<::std::string::String>,
/// <p>Specifies the IAM role ARN used to create the target recovery point; for example, <code>arn:aws:iam::123456789012:role/S3Access</code>.</p>
pub iam_role_arn: ::std::option::Option<::std::string::String>,
/// <p>A customer-chosen string that you can use to distinguish between otherwise identical calls to <code>StartScanJob</code>. Retrying a successful request with the same idempotency token results in a success message with no action taken.</p>
pub idempotency_token: ::std::option::Option<::std::string::String>,
/// <p>Specifies the malware scanner used during the scan job. Currently only supports <code>GUARDDUTY</code>.</p>
pub malware_scanner: ::std::option::Option<crate::types::MalwareScanner>,
/// <p>An Amazon Resource Name (ARN) that uniquely identifies a recovery point. This is your target recovery point for a full scan. If you are running an incremental scan, this will be your a recovery point which has been created after your base recovery point selection.</p>
pub recovery_point_arn: ::std::option::Option<::std::string::String>,
/// <p>An ARN that uniquely identifies the base recovery point to be used for incremental scanning.</p>
pub scan_base_recovery_point_arn: ::std::option::Option<::std::string::String>,
/// <p>Specifies the scan type use for the scan job.</p>
/// <p>Includes:</p>
/// <ul>
/// <li>
/// <p><code>FULL_SCAN</code> will scan the entire data lineage within the backup.</p></li>
/// <li>
/// <p><code>INCREMENTAL_SCAN</code> will scan the data difference between the target recovery point and base recovery point ARN.</p></li>
/// </ul>
pub scan_mode: ::std::option::Option<crate::types::ScanMode>,
/// <p>Specified the IAM scanner role ARN.</p>
pub scanner_role_arn: ::std::option::Option<::std::string::String>,
}
impl StartScanJobInput {
/// <p>The name of a logical container where backups are stored. Backup vaults are identified by names that are unique to the account used to create them and the Amazon Web Services Region where they are created.</p>
/// <p>Pattern: <code>^\[a-zA-Z0-9\-\_\]{2,50}$</code></p>
pub fn backup_vault_name(&self) -> ::std::option::Option<&str> {
self.backup_vault_name.as_deref()
}
/// <p>Specifies the IAM role ARN used to create the target recovery point; for example, <code>arn:aws:iam::123456789012:role/S3Access</code>.</p>
pub fn iam_role_arn(&self) -> ::std::option::Option<&str> {
self.iam_role_arn.as_deref()
}
/// <p>A customer-chosen string that you can use to distinguish between otherwise identical calls to <code>StartScanJob</code>. Retrying a successful request with the same idempotency token results in a success message with no action taken.</p>
pub fn idempotency_token(&self) -> ::std::option::Option<&str> {
self.idempotency_token.as_deref()
}
/// <p>Specifies the malware scanner used during the scan job. Currently only supports <code>GUARDDUTY</code>.</p>
pub fn malware_scanner(&self) -> ::std::option::Option<&crate::types::MalwareScanner> {
self.malware_scanner.as_ref()
}
/// <p>An Amazon Resource Name (ARN) that uniquely identifies a recovery point. This is your target recovery point for a full scan. If you are running an incremental scan, this will be your a recovery point which has been created after your base recovery point selection.</p>
pub fn recovery_point_arn(&self) -> ::std::option::Option<&str> {
self.recovery_point_arn.as_deref()
}
/// <p>An ARN that uniquely identifies the base recovery point to be used for incremental scanning.</p>
pub fn scan_base_recovery_point_arn(&self) -> ::std::option::Option<&str> {
self.scan_base_recovery_point_arn.as_deref()
}
/// <p>Specifies the scan type use for the scan job.</p>
/// <p>Includes:</p>
/// <ul>
/// <li>
/// <p><code>FULL_SCAN</code> will scan the entire data lineage within the backup.</p></li>
/// <li>
/// <p><code>INCREMENTAL_SCAN</code> will scan the data difference between the target recovery point and base recovery point ARN.</p></li>
/// </ul>
pub fn scan_mode(&self) -> ::std::option::Option<&crate::types::ScanMode> {
self.scan_mode.as_ref()
}
/// <p>Specified the IAM scanner role ARN.</p>
pub fn scanner_role_arn(&self) -> ::std::option::Option<&str> {
self.scanner_role_arn.as_deref()
}
}
impl StartScanJobInput {
/// Creates a new builder-style object to manufacture [`StartScanJobInput`](crate::operation::start_scan_job::StartScanJobInput).
pub fn builder() -> crate::operation::start_scan_job::builders::StartScanJobInputBuilder {
crate::operation::start_scan_job::builders::StartScanJobInputBuilder::default()
}
}
/// A builder for [`StartScanJobInput`](crate::operation::start_scan_job::StartScanJobInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct StartScanJobInputBuilder {
pub(crate) backup_vault_name: ::std::option::Option<::std::string::String>,
pub(crate) iam_role_arn: ::std::option::Option<::std::string::String>,
pub(crate) idempotency_token: ::std::option::Option<::std::string::String>,
pub(crate) malware_scanner: ::std::option::Option<crate::types::MalwareScanner>,
pub(crate) recovery_point_arn: ::std::option::Option<::std::string::String>,
pub(crate) scan_base_recovery_point_arn: ::std::option::Option<::std::string::String>,
pub(crate) scan_mode: ::std::option::Option<crate::types::ScanMode>,
pub(crate) scanner_role_arn: ::std::option::Option<::std::string::String>,
}
impl StartScanJobInputBuilder {
/// <p>The name of a logical container where backups are stored. Backup vaults are identified by names that are unique to the account used to create them and the Amazon Web Services Region where they are created.</p>
/// <p>Pattern: <code>^\[a-zA-Z0-9\-\_\]{2,50}$</code></p>
/// This field is required.
pub fn backup_vault_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.backup_vault_name = ::std::option::Option::Some(input.into());
self
}
/// <p>The name of a logical container where backups are stored. Backup vaults are identified by names that are unique to the account used to create them and the Amazon Web Services Region where they are created.</p>
/// <p>Pattern: <code>^\[a-zA-Z0-9\-\_\]{2,50}$</code></p>
pub fn set_backup_vault_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.backup_vault_name = input;
self
}
/// <p>The name of a logical container where backups are stored. Backup vaults are identified by names that are unique to the account used to create them and the Amazon Web Services Region where they are created.</p>
/// <p>Pattern: <code>^\[a-zA-Z0-9\-\_\]{2,50}$</code></p>
pub fn get_backup_vault_name(&self) -> &::std::option::Option<::std::string::String> {
&self.backup_vault_name
}
/// <p>Specifies the IAM role ARN used to create the target recovery point; for example, <code>arn:aws:iam::123456789012:role/S3Access</code>.</p>
/// This field is required.
pub fn iam_role_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.iam_role_arn = ::std::option::Option::Some(input.into());
self
}
/// <p>Specifies the IAM role ARN used to create the target recovery point; for example, <code>arn:aws:iam::123456789012:role/S3Access</code>.</p>
pub fn set_iam_role_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.iam_role_arn = input;
self
}
/// <p>Specifies the IAM role ARN used to create the target recovery point; for example, <code>arn:aws:iam::123456789012:role/S3Access</code>.</p>
pub fn get_iam_role_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.iam_role_arn
}
/// <p>A customer-chosen string that you can use to distinguish between otherwise identical calls to <code>StartScanJob</code>. Retrying a successful request with the same idempotency token results in a success message with no action taken.</p>
pub fn idempotency_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.idempotency_token = ::std::option::Option::Some(input.into());
self
}
/// <p>A customer-chosen string that you can use to distinguish between otherwise identical calls to <code>StartScanJob</code>. Retrying a successful request with the same idempotency token results in a success message with no action taken.</p>
pub fn set_idempotency_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.idempotency_token = input;
self
}
/// <p>A customer-chosen string that you can use to distinguish between otherwise identical calls to <code>StartScanJob</code>. Retrying a successful request with the same idempotency token results in a success message with no action taken.</p>
pub fn get_idempotency_token(&self) -> &::std::option::Option<::std::string::String> {
&self.idempotency_token
}
/// <p>Specifies the malware scanner used during the scan job. Currently only supports <code>GUARDDUTY</code>.</p>
/// This field is required.
pub fn malware_scanner(mut self, input: crate::types::MalwareScanner) -> Self {
self.malware_scanner = ::std::option::Option::Some(input);
self
}
/// <p>Specifies the malware scanner used during the scan job. Currently only supports <code>GUARDDUTY</code>.</p>
pub fn set_malware_scanner(mut self, input: ::std::option::Option<crate::types::MalwareScanner>) -> Self {
self.malware_scanner = input;
self
}
/// <p>Specifies the malware scanner used during the scan job. Currently only supports <code>GUARDDUTY</code>.</p>
pub fn get_malware_scanner(&self) -> &::std::option::Option<crate::types::MalwareScanner> {
&self.malware_scanner
}
/// <p>An Amazon Resource Name (ARN) that uniquely identifies a recovery point. This is your target recovery point for a full scan. If you are running an incremental scan, this will be your a recovery point which has been created after your base recovery point selection.</p>
/// This field is required.
pub fn recovery_point_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.recovery_point_arn = ::std::option::Option::Some(input.into());
self
}
/// <p>An Amazon Resource Name (ARN) that uniquely identifies a recovery point. This is your target recovery point for a full scan. If you are running an incremental scan, this will be your a recovery point which has been created after your base recovery point selection.</p>
pub fn set_recovery_point_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.recovery_point_arn = input;
self
}
/// <p>An Amazon Resource Name (ARN) that uniquely identifies a recovery point. This is your target recovery point for a full scan. If you are running an incremental scan, this will be your a recovery point which has been created after your base recovery point selection.</p>
pub fn get_recovery_point_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.recovery_point_arn
}
/// <p>An ARN that uniquely identifies the base recovery point to be used for incremental scanning.</p>
pub fn scan_base_recovery_point_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.scan_base_recovery_point_arn = ::std::option::Option::Some(input.into());
self
}
/// <p>An ARN that uniquely identifies the base recovery point to be used for incremental scanning.</p>
pub fn set_scan_base_recovery_point_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.scan_base_recovery_point_arn = input;
self
}
/// <p>An ARN that uniquely identifies the base recovery point to be used for incremental scanning.</p>
pub fn get_scan_base_recovery_point_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.scan_base_recovery_point_arn
}
/// <p>Specifies the scan type use for the scan job.</p>
/// <p>Includes:</p>
/// <ul>
/// <li>
/// <p><code>FULL_SCAN</code> will scan the entire data lineage within the backup.</p></li>
/// <li>
/// <p><code>INCREMENTAL_SCAN</code> will scan the data difference between the target recovery point and base recovery point ARN.</p></li>
/// </ul>
/// This field is required.
pub fn scan_mode(mut self, input: crate::types::ScanMode) -> Self {
self.scan_mode = ::std::option::Option::Some(input);
self
}
/// <p>Specifies the scan type use for the scan job.</p>
/// <p>Includes:</p>
/// <ul>
/// <li>
/// <p><code>FULL_SCAN</code> will scan the entire data lineage within the backup.</p></li>
/// <li>
/// <p><code>INCREMENTAL_SCAN</code> will scan the data difference between the target recovery point and base recovery point ARN.</p></li>
/// </ul>
pub fn set_scan_mode(mut self, input: ::std::option::Option<crate::types::ScanMode>) -> Self {
self.scan_mode = input;
self
}
/// <p>Specifies the scan type use for the scan job.</p>
/// <p>Includes:</p>
/// <ul>
/// <li>
/// <p><code>FULL_SCAN</code> will scan the entire data lineage within the backup.</p></li>
/// <li>
/// <p><code>INCREMENTAL_SCAN</code> will scan the data difference between the target recovery point and base recovery point ARN.</p></li>
/// </ul>
pub fn get_scan_mode(&self) -> &::std::option::Option<crate::types::ScanMode> {
&self.scan_mode
}
/// <p>Specified the IAM scanner role ARN.</p>
/// This field is required.
pub fn scanner_role_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.scanner_role_arn = ::std::option::Option::Some(input.into());
self
}
/// <p>Specified the IAM scanner role ARN.</p>
pub fn set_scanner_role_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.scanner_role_arn = input;
self
}
/// <p>Specified the IAM scanner role ARN.</p>
pub fn get_scanner_role_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.scanner_role_arn
}
/// Consumes the builder and constructs a [`StartScanJobInput`](crate::operation::start_scan_job::StartScanJobInput).
pub fn build(
self,
) -> ::std::result::Result<crate::operation::start_scan_job::StartScanJobInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::start_scan_job::StartScanJobInput {
backup_vault_name: self.backup_vault_name,
iam_role_arn: self.iam_role_arn,
idempotency_token: self.idempotency_token,
malware_scanner: self.malware_scanner,
recovery_point_arn: self.recovery_point_arn,
scan_base_recovery_point_arn: self.scan_base_recovery_point_arn,
scan_mode: self.scan_mode,
scanner_role_arn: self.scanner_role_arn,
})
}
}