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
// 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 StartResourceEvaluationInput {
/// <p>Returns a <code>ResourceDetails</code> object.</p>
pub resource_details: ::std::option::Option<crate::types::ResourceDetails>,
/// <p>Returns an <code>EvaluationContext</code> object.</p>
pub evaluation_context: ::std::option::Option<crate::types::EvaluationContext>,
/// <p>The mode of an evaluation.</p><note>
/// <p>The only valid value for this API is <code>PROACTIVE</code>.</p>
/// </note>
pub evaluation_mode: ::std::option::Option<crate::types::EvaluationMode>,
/// <p>The timeout for an evaluation. The default is 900 seconds. You cannot specify a number greater than 3600. If you specify 0, Config uses the default.</p>
pub evaluation_timeout: ::std::option::Option<i32>,
/// <p>A client token is a unique, case-sensitive string of up to 64 ASCII characters. To make an idempotent API request using one of these actions, specify a client token in the request.</p><note>
/// <p>Avoid reusing the same client token for other API requests. If you retry a request that completed successfully using the same client token and the same parameters, the retry succeeds without performing any further actions. If you retry a successful request using the same client token, but one or more of the parameters are different, other than the Region or Availability Zone, the retry fails with an IdempotentParameterMismatch error.</p>
/// </note>
pub client_token: ::std::option::Option<::std::string::String>,
}
impl StartResourceEvaluationInput {
/// <p>Returns a <code>ResourceDetails</code> object.</p>
pub fn resource_details(&self) -> ::std::option::Option<&crate::types::ResourceDetails> {
self.resource_details.as_ref()
}
/// <p>Returns an <code>EvaluationContext</code> object.</p>
pub fn evaluation_context(&self) -> ::std::option::Option<&crate::types::EvaluationContext> {
self.evaluation_context.as_ref()
}
/// <p>The mode of an evaluation.</p><note>
/// <p>The only valid value for this API is <code>PROACTIVE</code>.</p>
/// </note>
pub fn evaluation_mode(&self) -> ::std::option::Option<&crate::types::EvaluationMode> {
self.evaluation_mode.as_ref()
}
/// <p>The timeout for an evaluation. The default is 900 seconds. You cannot specify a number greater than 3600. If you specify 0, Config uses the default.</p>
pub fn evaluation_timeout(&self) -> ::std::option::Option<i32> {
self.evaluation_timeout
}
/// <p>A client token is a unique, case-sensitive string of up to 64 ASCII characters. To make an idempotent API request using one of these actions, specify a client token in the request.</p><note>
/// <p>Avoid reusing the same client token for other API requests. If you retry a request that completed successfully using the same client token and the same parameters, the retry succeeds without performing any further actions. If you retry a successful request using the same client token, but one or more of the parameters are different, other than the Region or Availability Zone, the retry fails with an IdempotentParameterMismatch error.</p>
/// </note>
pub fn client_token(&self) -> ::std::option::Option<&str> {
self.client_token.as_deref()
}
}
impl StartResourceEvaluationInput {
/// Creates a new builder-style object to manufacture [`StartResourceEvaluationInput`](crate::operation::start_resource_evaluation::StartResourceEvaluationInput).
pub fn builder() -> crate::operation::start_resource_evaluation::builders::StartResourceEvaluationInputBuilder {
crate::operation::start_resource_evaluation::builders::StartResourceEvaluationInputBuilder::default()
}
}
/// A builder for [`StartResourceEvaluationInput`](crate::operation::start_resource_evaluation::StartResourceEvaluationInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct StartResourceEvaluationInputBuilder {
pub(crate) resource_details: ::std::option::Option<crate::types::ResourceDetails>,
pub(crate) evaluation_context: ::std::option::Option<crate::types::EvaluationContext>,
pub(crate) evaluation_mode: ::std::option::Option<crate::types::EvaluationMode>,
pub(crate) evaluation_timeout: ::std::option::Option<i32>,
pub(crate) client_token: ::std::option::Option<::std::string::String>,
}
impl StartResourceEvaluationInputBuilder {
/// <p>Returns a <code>ResourceDetails</code> object.</p>
/// This field is required.
pub fn resource_details(mut self, input: crate::types::ResourceDetails) -> Self {
self.resource_details = ::std::option::Option::Some(input);
self
}
/// <p>Returns a <code>ResourceDetails</code> object.</p>
pub fn set_resource_details(mut self, input: ::std::option::Option<crate::types::ResourceDetails>) -> Self {
self.resource_details = input;
self
}
/// <p>Returns a <code>ResourceDetails</code> object.</p>
pub fn get_resource_details(&self) -> &::std::option::Option<crate::types::ResourceDetails> {
&self.resource_details
}
/// <p>Returns an <code>EvaluationContext</code> object.</p>
pub fn evaluation_context(mut self, input: crate::types::EvaluationContext) -> Self {
self.evaluation_context = ::std::option::Option::Some(input);
self
}
/// <p>Returns an <code>EvaluationContext</code> object.</p>
pub fn set_evaluation_context(mut self, input: ::std::option::Option<crate::types::EvaluationContext>) -> Self {
self.evaluation_context = input;
self
}
/// <p>Returns an <code>EvaluationContext</code> object.</p>
pub fn get_evaluation_context(&self) -> &::std::option::Option<crate::types::EvaluationContext> {
&self.evaluation_context
}
/// <p>The mode of an evaluation.</p><note>
/// <p>The only valid value for this API is <code>PROACTIVE</code>.</p>
/// </note>
/// This field is required.
pub fn evaluation_mode(mut self, input: crate::types::EvaluationMode) -> Self {
self.evaluation_mode = ::std::option::Option::Some(input);
self
}
/// <p>The mode of an evaluation.</p><note>
/// <p>The only valid value for this API is <code>PROACTIVE</code>.</p>
/// </note>
pub fn set_evaluation_mode(mut self, input: ::std::option::Option<crate::types::EvaluationMode>) -> Self {
self.evaluation_mode = input;
self
}
/// <p>The mode of an evaluation.</p><note>
/// <p>The only valid value for this API is <code>PROACTIVE</code>.</p>
/// </note>
pub fn get_evaluation_mode(&self) -> &::std::option::Option<crate::types::EvaluationMode> {
&self.evaluation_mode
}
/// <p>The timeout for an evaluation. The default is 900 seconds. You cannot specify a number greater than 3600. If you specify 0, Config uses the default.</p>
pub fn evaluation_timeout(mut self, input: i32) -> Self {
self.evaluation_timeout = ::std::option::Option::Some(input);
self
}
/// <p>The timeout for an evaluation. The default is 900 seconds. You cannot specify a number greater than 3600. If you specify 0, Config uses the default.</p>
pub fn set_evaluation_timeout(mut self, input: ::std::option::Option<i32>) -> Self {
self.evaluation_timeout = input;
self
}
/// <p>The timeout for an evaluation. The default is 900 seconds. You cannot specify a number greater than 3600. If you specify 0, Config uses the default.</p>
pub fn get_evaluation_timeout(&self) -> &::std::option::Option<i32> {
&self.evaluation_timeout
}
/// <p>A client token is a unique, case-sensitive string of up to 64 ASCII characters. To make an idempotent API request using one of these actions, specify a client token in the request.</p><note>
/// <p>Avoid reusing the same client token for other API requests. If you retry a request that completed successfully using the same client token and the same parameters, the retry succeeds without performing any further actions. If you retry a successful request using the same client token, but one or more of the parameters are different, other than the Region or Availability Zone, the retry fails with an IdempotentParameterMismatch error.</p>
/// </note>
pub fn client_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.client_token = ::std::option::Option::Some(input.into());
self
}
/// <p>A client token is a unique, case-sensitive string of up to 64 ASCII characters. To make an idempotent API request using one of these actions, specify a client token in the request.</p><note>
/// <p>Avoid reusing the same client token for other API requests. If you retry a request that completed successfully using the same client token and the same parameters, the retry succeeds without performing any further actions. If you retry a successful request using the same client token, but one or more of the parameters are different, other than the Region or Availability Zone, the retry fails with an IdempotentParameterMismatch error.</p>
/// </note>
pub fn set_client_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.client_token = input;
self
}
/// <p>A client token is a unique, case-sensitive string of up to 64 ASCII characters. To make an idempotent API request using one of these actions, specify a client token in the request.</p><note>
/// <p>Avoid reusing the same client token for other API requests. If you retry a request that completed successfully using the same client token and the same parameters, the retry succeeds without performing any further actions. If you retry a successful request using the same client token, but one or more of the parameters are different, other than the Region or Availability Zone, the retry fails with an IdempotentParameterMismatch error.</p>
/// </note>
pub fn get_client_token(&self) -> &::std::option::Option<::std::string::String> {
&self.client_token
}
/// Consumes the builder and constructs a [`StartResourceEvaluationInput`](crate::operation::start_resource_evaluation::StartResourceEvaluationInput).
pub fn build(
self,
) -> ::std::result::Result<
crate::operation::start_resource_evaluation::StartResourceEvaluationInput,
::aws_smithy_types::error::operation::BuildError,
> {
::std::result::Result::Ok(crate::operation::start_resource_evaluation::StartResourceEvaluationInput {
resource_details: self.resource_details,
evaluation_context: self.evaluation_context,
evaluation_mode: self.evaluation_mode,
evaluation_timeout: self.evaluation_timeout,
client_token: self.client_token,
})
}
}