aws_sdk_elasticbeanstalk/operation/describe_events/
_describe_events_input.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2
3/// <p>Request to retrieve a list of events for an environment.</p>
4#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct DescribeEventsInput {
7    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to include only those associated with this application.</p>
8    pub application_name: ::std::option::Option<::std::string::String>,
9    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this application version.</p>
10    pub version_label: ::std::option::Option<::std::string::String>,
11    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that are associated with this environment configuration.</p>
12    pub template_name: ::std::option::Option<::std::string::String>,
13    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.</p>
14    pub environment_id: ::std::option::Option<::std::string::String>,
15    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.</p>
16    pub environment_name: ::std::option::Option<::std::string::String>,
17    /// <p>The ARN of a custom platform version. If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this custom platform version.</p>
18    pub platform_arn: ::std::option::Option<::std::string::String>,
19    /// <p>If specified, AWS Elastic Beanstalk restricts the described events to include only those associated with this request ID.</p>
20    pub request_id: ::std::option::Option<::std::string::String>,
21    /// <p>If specified, limits the events returned from this call to include only those with the specified severity or higher.</p>
22    pub severity: ::std::option::Option<crate::types::EventSeverity>,
23    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur on or after this time.</p>
24    pub start_time: ::std::option::Option<::aws_smithy_types::DateTime>,
25    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur up to, but not including, the <code>EndTime</code>.</p>
26    pub end_time: ::std::option::Option<::aws_smithy_types::DateTime>,
27    /// <p>Specifies the maximum number of events that can be returned, beginning with the most recent event.</p>
28    pub max_records: ::std::option::Option<i32>,
29    /// <p>Pagination token. If specified, the events return the next batch of results.</p>
30    pub next_token: ::std::option::Option<::std::string::String>,
31}
32impl DescribeEventsInput {
33    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to include only those associated with this application.</p>
34    pub fn application_name(&self) -> ::std::option::Option<&str> {
35        self.application_name.as_deref()
36    }
37    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this application version.</p>
38    pub fn version_label(&self) -> ::std::option::Option<&str> {
39        self.version_label.as_deref()
40    }
41    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that are associated with this environment configuration.</p>
42    pub fn template_name(&self) -> ::std::option::Option<&str> {
43        self.template_name.as_deref()
44    }
45    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.</p>
46    pub fn environment_id(&self) -> ::std::option::Option<&str> {
47        self.environment_id.as_deref()
48    }
49    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.</p>
50    pub fn environment_name(&self) -> ::std::option::Option<&str> {
51        self.environment_name.as_deref()
52    }
53    /// <p>The ARN of a custom platform version. If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this custom platform version.</p>
54    pub fn platform_arn(&self) -> ::std::option::Option<&str> {
55        self.platform_arn.as_deref()
56    }
57    /// <p>If specified, AWS Elastic Beanstalk restricts the described events to include only those associated with this request ID.</p>
58    pub fn request_id(&self) -> ::std::option::Option<&str> {
59        self.request_id.as_deref()
60    }
61    /// <p>If specified, limits the events returned from this call to include only those with the specified severity or higher.</p>
62    pub fn severity(&self) -> ::std::option::Option<&crate::types::EventSeverity> {
63        self.severity.as_ref()
64    }
65    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur on or after this time.</p>
66    pub fn start_time(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
67        self.start_time.as_ref()
68    }
69    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur up to, but not including, the <code>EndTime</code>.</p>
70    pub fn end_time(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
71        self.end_time.as_ref()
72    }
73    /// <p>Specifies the maximum number of events that can be returned, beginning with the most recent event.</p>
74    pub fn max_records(&self) -> ::std::option::Option<i32> {
75        self.max_records
76    }
77    /// <p>Pagination token. If specified, the events return the next batch of results.</p>
78    pub fn next_token(&self) -> ::std::option::Option<&str> {
79        self.next_token.as_deref()
80    }
81}
82impl DescribeEventsInput {
83    /// Creates a new builder-style object to manufacture [`DescribeEventsInput`](crate::operation::describe_events::DescribeEventsInput).
84    pub fn builder() -> crate::operation::describe_events::builders::DescribeEventsInputBuilder {
85        crate::operation::describe_events::builders::DescribeEventsInputBuilder::default()
86    }
87}
88
89/// A builder for [`DescribeEventsInput`](crate::operation::describe_events::DescribeEventsInput).
90#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
91#[non_exhaustive]
92pub struct DescribeEventsInputBuilder {
93    pub(crate) application_name: ::std::option::Option<::std::string::String>,
94    pub(crate) version_label: ::std::option::Option<::std::string::String>,
95    pub(crate) template_name: ::std::option::Option<::std::string::String>,
96    pub(crate) environment_id: ::std::option::Option<::std::string::String>,
97    pub(crate) environment_name: ::std::option::Option<::std::string::String>,
98    pub(crate) platform_arn: ::std::option::Option<::std::string::String>,
99    pub(crate) request_id: ::std::option::Option<::std::string::String>,
100    pub(crate) severity: ::std::option::Option<crate::types::EventSeverity>,
101    pub(crate) start_time: ::std::option::Option<::aws_smithy_types::DateTime>,
102    pub(crate) end_time: ::std::option::Option<::aws_smithy_types::DateTime>,
103    pub(crate) max_records: ::std::option::Option<i32>,
104    pub(crate) next_token: ::std::option::Option<::std::string::String>,
105}
106impl DescribeEventsInputBuilder {
107    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to include only those associated with this application.</p>
108    pub fn application_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
109        self.application_name = ::std::option::Option::Some(input.into());
110        self
111    }
112    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to include only those associated with this application.</p>
113    pub fn set_application_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
114        self.application_name = input;
115        self
116    }
117    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to include only those associated with this application.</p>
118    pub fn get_application_name(&self) -> &::std::option::Option<::std::string::String> {
119        &self.application_name
120    }
121    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this application version.</p>
122    pub fn version_label(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
123        self.version_label = ::std::option::Option::Some(input.into());
124        self
125    }
126    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this application version.</p>
127    pub fn set_version_label(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
128        self.version_label = input;
129        self
130    }
131    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this application version.</p>
132    pub fn get_version_label(&self) -> &::std::option::Option<::std::string::String> {
133        &self.version_label
134    }
135    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that are associated with this environment configuration.</p>
136    pub fn template_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
137        self.template_name = ::std::option::Option::Some(input.into());
138        self
139    }
140    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that are associated with this environment configuration.</p>
141    pub fn set_template_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
142        self.template_name = input;
143        self
144    }
145    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that are associated with this environment configuration.</p>
146    pub fn get_template_name(&self) -> &::std::option::Option<::std::string::String> {
147        &self.template_name
148    }
149    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.</p>
150    pub fn environment_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
151        self.environment_id = ::std::option::Option::Some(input.into());
152        self
153    }
154    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.</p>
155    pub fn set_environment_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
156        self.environment_id = input;
157        self
158    }
159    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.</p>
160    pub fn get_environment_id(&self) -> &::std::option::Option<::std::string::String> {
161        &self.environment_id
162    }
163    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.</p>
164    pub fn environment_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
165        self.environment_name = ::std::option::Option::Some(input.into());
166        self
167    }
168    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.</p>
169    pub fn set_environment_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
170        self.environment_name = input;
171        self
172    }
173    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this environment.</p>
174    pub fn get_environment_name(&self) -> &::std::option::Option<::std::string::String> {
175        &self.environment_name
176    }
177    /// <p>The ARN of a custom platform version. If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this custom platform version.</p>
178    pub fn platform_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
179        self.platform_arn = ::std::option::Option::Some(input.into());
180        self
181    }
182    /// <p>The ARN of a custom platform version. If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this custom platform version.</p>
183    pub fn set_platform_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
184        self.platform_arn = input;
185        self
186    }
187    /// <p>The ARN of a custom platform version. If specified, AWS Elastic Beanstalk restricts the returned descriptions to those associated with this custom platform version.</p>
188    pub fn get_platform_arn(&self) -> &::std::option::Option<::std::string::String> {
189        &self.platform_arn
190    }
191    /// <p>If specified, AWS Elastic Beanstalk restricts the described events to include only those associated with this request ID.</p>
192    pub fn request_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
193        self.request_id = ::std::option::Option::Some(input.into());
194        self
195    }
196    /// <p>If specified, AWS Elastic Beanstalk restricts the described events to include only those associated with this request ID.</p>
197    pub fn set_request_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
198        self.request_id = input;
199        self
200    }
201    /// <p>If specified, AWS Elastic Beanstalk restricts the described events to include only those associated with this request ID.</p>
202    pub fn get_request_id(&self) -> &::std::option::Option<::std::string::String> {
203        &self.request_id
204    }
205    /// <p>If specified, limits the events returned from this call to include only those with the specified severity or higher.</p>
206    pub fn severity(mut self, input: crate::types::EventSeverity) -> Self {
207        self.severity = ::std::option::Option::Some(input);
208        self
209    }
210    /// <p>If specified, limits the events returned from this call to include only those with the specified severity or higher.</p>
211    pub fn set_severity(mut self, input: ::std::option::Option<crate::types::EventSeverity>) -> Self {
212        self.severity = input;
213        self
214    }
215    /// <p>If specified, limits the events returned from this call to include only those with the specified severity or higher.</p>
216    pub fn get_severity(&self) -> &::std::option::Option<crate::types::EventSeverity> {
217        &self.severity
218    }
219    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur on or after this time.</p>
220    pub fn start_time(mut self, input: ::aws_smithy_types::DateTime) -> Self {
221        self.start_time = ::std::option::Option::Some(input);
222        self
223    }
224    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur on or after this time.</p>
225    pub fn set_start_time(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
226        self.start_time = input;
227        self
228    }
229    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur on or after this time.</p>
230    pub fn get_start_time(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
231        &self.start_time
232    }
233    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur up to, but not including, the <code>EndTime</code>.</p>
234    pub fn end_time(mut self, input: ::aws_smithy_types::DateTime) -> Self {
235        self.end_time = ::std::option::Option::Some(input);
236        self
237    }
238    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur up to, but not including, the <code>EndTime</code>.</p>
239    pub fn set_end_time(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
240        self.end_time = input;
241        self
242    }
243    /// <p>If specified, AWS Elastic Beanstalk restricts the returned descriptions to those that occur up to, but not including, the <code>EndTime</code>.</p>
244    pub fn get_end_time(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
245        &self.end_time
246    }
247    /// <p>Specifies the maximum number of events that can be returned, beginning with the most recent event.</p>
248    pub fn max_records(mut self, input: i32) -> Self {
249        self.max_records = ::std::option::Option::Some(input);
250        self
251    }
252    /// <p>Specifies the maximum number of events that can be returned, beginning with the most recent event.</p>
253    pub fn set_max_records(mut self, input: ::std::option::Option<i32>) -> Self {
254        self.max_records = input;
255        self
256    }
257    /// <p>Specifies the maximum number of events that can be returned, beginning with the most recent event.</p>
258    pub fn get_max_records(&self) -> &::std::option::Option<i32> {
259        &self.max_records
260    }
261    /// <p>Pagination token. If specified, the events return the next batch of results.</p>
262    pub fn next_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
263        self.next_token = ::std::option::Option::Some(input.into());
264        self
265    }
266    /// <p>Pagination token. If specified, the events return the next batch of results.</p>
267    pub fn set_next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
268        self.next_token = input;
269        self
270    }
271    /// <p>Pagination token. If specified, the events return the next batch of results.</p>
272    pub fn get_next_token(&self) -> &::std::option::Option<::std::string::String> {
273        &self.next_token
274    }
275    /// Consumes the builder and constructs a [`DescribeEventsInput`](crate::operation::describe_events::DescribeEventsInput).
276    pub fn build(
277        self,
278    ) -> ::std::result::Result<crate::operation::describe_events::DescribeEventsInput, ::aws_smithy_types::error::operation::BuildError> {
279        ::std::result::Result::Ok(crate::operation::describe_events::DescribeEventsInput {
280            application_name: self.application_name,
281            version_label: self.version_label,
282            template_name: self.template_name,
283            environment_id: self.environment_id,
284            environment_name: self.environment_name,
285            platform_arn: self.platform_arn,
286            request_id: self.request_id,
287            severity: self.severity,
288            start_time: self.start_time,
289            end_time: self.end_time,
290            max_records: self.max_records,
291            next_token: self.next_token,
292        })
293    }
294}