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
// 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 GetTokenBalanceInput {
/// <p>The container for the identifier for the token, including the unique token ID and its blockchain network.</p>
pub token_identifier: ::std::option::Option<crate::types::TokenIdentifier>,
/// <p>The container for the identifier for the owner.</p>
pub owner_identifier: ::std::option::Option<crate::types::OwnerIdentifier>,
/// <p>The time for when the TokenBalance is requested or the current time if a time is not provided in the request.</p><note>
/// <p>This time will only be recorded up to the second.</p>
/// </note>
pub at_blockchain_instant: ::std::option::Option<crate::types::BlockchainInstant>,
}
impl GetTokenBalanceInput {
/// <p>The container for the identifier for the token, including the unique token ID and its blockchain network.</p>
pub fn token_identifier(&self) -> ::std::option::Option<&crate::types::TokenIdentifier> {
self.token_identifier.as_ref()
}
/// <p>The container for the identifier for the owner.</p>
pub fn owner_identifier(&self) -> ::std::option::Option<&crate::types::OwnerIdentifier> {
self.owner_identifier.as_ref()
}
/// <p>The time for when the TokenBalance is requested or the current time if a time is not provided in the request.</p><note>
/// <p>This time will only be recorded up to the second.</p>
/// </note>
pub fn at_blockchain_instant(&self) -> ::std::option::Option<&crate::types::BlockchainInstant> {
self.at_blockchain_instant.as_ref()
}
}
impl GetTokenBalanceInput {
/// Creates a new builder-style object to manufacture [`GetTokenBalanceInput`](crate::operation::get_token_balance::GetTokenBalanceInput).
pub fn builder() -> crate::operation::get_token_balance::builders::GetTokenBalanceInputBuilder {
crate::operation::get_token_balance::builders::GetTokenBalanceInputBuilder::default()
}
}
/// A builder for [`GetTokenBalanceInput`](crate::operation::get_token_balance::GetTokenBalanceInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetTokenBalanceInputBuilder {
pub(crate) token_identifier: ::std::option::Option<crate::types::TokenIdentifier>,
pub(crate) owner_identifier: ::std::option::Option<crate::types::OwnerIdentifier>,
pub(crate) at_blockchain_instant: ::std::option::Option<crate::types::BlockchainInstant>,
}
impl GetTokenBalanceInputBuilder {
/// <p>The container for the identifier for the token, including the unique token ID and its blockchain network.</p>
/// This field is required.
pub fn token_identifier(mut self, input: crate::types::TokenIdentifier) -> Self {
self.token_identifier = ::std::option::Option::Some(input);
self
}
/// <p>The container for the identifier for the token, including the unique token ID and its blockchain network.</p>
pub fn set_token_identifier(mut self, input: ::std::option::Option<crate::types::TokenIdentifier>) -> Self {
self.token_identifier = input;
self
}
/// <p>The container for the identifier for the token, including the unique token ID and its blockchain network.</p>
pub fn get_token_identifier(&self) -> &::std::option::Option<crate::types::TokenIdentifier> {
&self.token_identifier
}
/// <p>The container for the identifier for the owner.</p>
/// This field is required.
pub fn owner_identifier(mut self, input: crate::types::OwnerIdentifier) -> Self {
self.owner_identifier = ::std::option::Option::Some(input);
self
}
/// <p>The container for the identifier for the owner.</p>
pub fn set_owner_identifier(mut self, input: ::std::option::Option<crate::types::OwnerIdentifier>) -> Self {
self.owner_identifier = input;
self
}
/// <p>The container for the identifier for the owner.</p>
pub fn get_owner_identifier(&self) -> &::std::option::Option<crate::types::OwnerIdentifier> {
&self.owner_identifier
}
/// <p>The time for when the TokenBalance is requested or the current time if a time is not provided in the request.</p><note>
/// <p>This time will only be recorded up to the second.</p>
/// </note>
pub fn at_blockchain_instant(mut self, input: crate::types::BlockchainInstant) -> Self {
self.at_blockchain_instant = ::std::option::Option::Some(input);
self
}
/// <p>The time for when the TokenBalance is requested or the current time if a time is not provided in the request.</p><note>
/// <p>This time will only be recorded up to the second.</p>
/// </note>
pub fn set_at_blockchain_instant(mut self, input: ::std::option::Option<crate::types::BlockchainInstant>) -> Self {
self.at_blockchain_instant = input;
self
}
/// <p>The time for when the TokenBalance is requested or the current time if a time is not provided in the request.</p><note>
/// <p>This time will only be recorded up to the second.</p>
/// </note>
pub fn get_at_blockchain_instant(&self) -> &::std::option::Option<crate::types::BlockchainInstant> {
&self.at_blockchain_instant
}
/// Consumes the builder and constructs a [`GetTokenBalanceInput`](crate::operation::get_token_balance::GetTokenBalanceInput).
pub fn build(
self,
) -> ::std::result::Result<crate::operation::get_token_balance::GetTokenBalanceInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::get_token_balance::GetTokenBalanceInput {
token_identifier: self.token_identifier,
owner_identifier: self.owner_identifier,
at_blockchain_instant: self.at_blockchain_instant,
})
}
}