aws_sdk_dynamodb/operation/list_tags_of_resource/_list_tags_of_resource_input.rs
1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2#[allow(missing_docs)] // documentation missing in model
3#[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct ListTagsOfResourceInput {
6 /// <p>The Amazon DynamoDB resource with tags to be listed. This value is an Amazon Resource Name (ARN).</p>
7 pub resource_arn: ::std::option::Option<::std::string::String>,
8 /// <p>An optional string that, if supplied, must be copied from the output of a previous call to ListTagOfResource. When provided in this manner, this API fetches the next page of results.</p>
9 pub next_token: ::std::option::Option<::std::string::String>,
10}
11impl ListTagsOfResourceInput {
12 /// <p>The Amazon DynamoDB resource with tags to be listed. This value is an Amazon Resource Name (ARN).</p>
13 pub fn resource_arn(&self) -> ::std::option::Option<&str> {
14 self.resource_arn.as_deref()
15 }
16 /// <p>An optional string that, if supplied, must be copied from the output of a previous call to ListTagOfResource. When provided in this manner, this API fetches the next page of results.</p>
17 pub fn next_token(&self) -> ::std::option::Option<&str> {
18 self.next_token.as_deref()
19 }
20}
21impl ListTagsOfResourceInput {
22 /// Creates a new builder-style object to manufacture [`ListTagsOfResourceInput`](crate::operation::list_tags_of_resource::ListTagsOfResourceInput).
23 pub fn builder() -> crate::operation::list_tags_of_resource::builders::ListTagsOfResourceInputBuilder {
24 crate::operation::list_tags_of_resource::builders::ListTagsOfResourceInputBuilder::default()
25 }
26}
27
28/// A builder for [`ListTagsOfResourceInput`](crate::operation::list_tags_of_resource::ListTagsOfResourceInput).
29#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
30#[non_exhaustive]
31pub struct ListTagsOfResourceInputBuilder {
32 pub(crate) resource_arn: ::std::option::Option<::std::string::String>,
33 pub(crate) next_token: ::std::option::Option<::std::string::String>,
34}
35impl ListTagsOfResourceInputBuilder {
36 /// <p>The Amazon DynamoDB resource with tags to be listed. This value is an Amazon Resource Name (ARN).</p>
37 /// This field is required.
38 pub fn resource_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
39 self.resource_arn = ::std::option::Option::Some(input.into());
40 self
41 }
42 /// <p>The Amazon DynamoDB resource with tags to be listed. This value is an Amazon Resource Name (ARN).</p>
43 pub fn set_resource_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
44 self.resource_arn = input;
45 self
46 }
47 /// <p>The Amazon DynamoDB resource with tags to be listed. This value is an Amazon Resource Name (ARN).</p>
48 pub fn get_resource_arn(&self) -> &::std::option::Option<::std::string::String> {
49 &self.resource_arn
50 }
51 /// <p>An optional string that, if supplied, must be copied from the output of a previous call to ListTagOfResource. When provided in this manner, this API fetches the next page of results.</p>
52 pub fn next_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
53 self.next_token = ::std::option::Option::Some(input.into());
54 self
55 }
56 /// <p>An optional string that, if supplied, must be copied from the output of a previous call to ListTagOfResource. When provided in this manner, this API fetches the next page of results.</p>
57 pub fn set_next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
58 self.next_token = input;
59 self
60 }
61 /// <p>An optional string that, if supplied, must be copied from the output of a previous call to ListTagOfResource. When provided in this manner, this API fetches the next page of results.</p>
62 pub fn get_next_token(&self) -> &::std::option::Option<::std::string::String> {
63 &self.next_token
64 }
65 /// Consumes the builder and constructs a [`ListTagsOfResourceInput`](crate::operation::list_tags_of_resource::ListTagsOfResourceInput).
66 pub fn build(
67 self,
68 ) -> ::std::result::Result<crate::operation::list_tags_of_resource::ListTagsOfResourceInput, ::aws_smithy_types::error::operation::BuildError>
69 {
70 ::std::result::Result::Ok(crate::operation::list_tags_of_resource::ListTagsOfResourceInput {
71 resource_arn: self.resource_arn,
72 next_token: self.next_token,
73 })
74 }
75}