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
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
/// <p>Represents a request to the list projects operation.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct ListProjectsInput {
/// <p>Optional. If no Amazon Resource Name (ARN) is specified, then AWS Device Farm returns a list of all projects for the AWS account. You can also specify a project ARN.</p>
pub arn: ::std::option::Option<::std::string::String>,
/// <p>An identifier that was returned from the previous call to this operation, which can be used to return the next set of items in the list.</p>
pub next_token: ::std::option::Option<::std::string::String>,
}
impl ListProjectsInput {
/// <p>Optional. If no Amazon Resource Name (ARN) is specified, then AWS Device Farm returns a list of all projects for the AWS account. You can also specify a project ARN.</p>
pub fn arn(&self) -> ::std::option::Option<&str> {
self.arn.as_deref()
}
/// <p>An identifier that was returned from the previous call to this operation, which can be used to return the next set of items in the list.</p>
pub fn next_token(&self) -> ::std::option::Option<&str> {
self.next_token.as_deref()
}
}
impl ListProjectsInput {
/// Creates a new builder-style object to manufacture [`ListProjectsInput`](crate::operation::list_projects::ListProjectsInput).
pub fn builder() -> crate::operation::list_projects::builders::ListProjectsInputBuilder {
crate::operation::list_projects::builders::ListProjectsInputBuilder::default()
}
}
/// A builder for [`ListProjectsInput`](crate::operation::list_projects::ListProjectsInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct ListProjectsInputBuilder {
pub(crate) arn: ::std::option::Option<::std::string::String>,
pub(crate) next_token: ::std::option::Option<::std::string::String>,
}
impl ListProjectsInputBuilder {
/// <p>Optional. If no Amazon Resource Name (ARN) is specified, then AWS Device Farm returns a list of all projects for the AWS account. You can also specify a project ARN.</p>
pub fn arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.arn = ::std::option::Option::Some(input.into());
self
}
/// <p>Optional. If no Amazon Resource Name (ARN) is specified, then AWS Device Farm returns a list of all projects for the AWS account. You can also specify a project ARN.</p>
pub fn set_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.arn = input;
self
}
/// <p>Optional. If no Amazon Resource Name (ARN) is specified, then AWS Device Farm returns a list of all projects for the AWS account. You can also specify a project ARN.</p>
pub fn get_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.arn
}
/// <p>An identifier that was returned from the previous call to this operation, which can be used to return the next set of items in the list.</p>
pub fn next_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.next_token = ::std::option::Option::Some(input.into());
self
}
/// <p>An identifier that was returned from the previous call to this operation, which can be used to return the next set of items in the list.</p>
pub fn set_next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.next_token = input;
self
}
/// <p>An identifier that was returned from the previous call to this operation, which can be used to return the next set of items in the list.</p>
pub fn get_next_token(&self) -> &::std::option::Option<::std::string::String> {
&self.next_token
}
/// Consumes the builder and constructs a [`ListProjectsInput`](crate::operation::list_projects::ListProjectsInput).
pub fn build(
self,
) -> ::std::result::Result<crate::operation::list_projects::ListProjectsInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::list_projects::ListProjectsInput {
arn: self.arn,
next_token: self.next_token,
})
}
}