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
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// <p>A container for information about a domain.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct DomainDescriptionType {
    /// <p>The user pool ID.</p>
    pub user_pool_id: ::std::option::Option<::std::string::String>,
    /// <p>The Amazon Web Services ID for the user pool owner.</p>
    pub aws_account_id: ::std::option::Option<::std::string::String>,
    /// <p>The domain string. For custom domains, this is the fully-qualified domain name, such as <code>auth.example.com</code>. For Amazon Cognito prefix domains, this is the prefix alone, such as <code>auth</code>.</p>
    pub domain: ::std::option::Option<::std::string::String>,
    /// <p>The Amazon S3 bucket where the static files for this domain are stored.</p>
    pub s3_bucket: ::std::option::Option<::std::string::String>,
    /// <p>The Amazon CloudFront endpoint that you use as the target of the alias that you set up with your Domain Name Service (DNS) provider.</p>
    pub cloud_front_distribution: ::std::option::Option<::std::string::String>,
    /// <p>The app version.</p>
    pub version: ::std::option::Option<::std::string::String>,
    /// <p>The domain status.</p>
    pub status: ::std::option::Option<crate::types::DomainStatusType>,
    /// <p>The configuration for a custom domain that hosts the sign-up and sign-in webpages for your application.</p>
    pub custom_domain_config: ::std::option::Option<crate::types::CustomDomainConfigType>,
}
impl DomainDescriptionType {
    /// <p>The user pool ID.</p>
    pub fn user_pool_id(&self) -> ::std::option::Option<&str> {
        self.user_pool_id.as_deref()
    }
    /// <p>The Amazon Web Services ID for the user pool owner.</p>
    pub fn aws_account_id(&self) -> ::std::option::Option<&str> {
        self.aws_account_id.as_deref()
    }
    /// <p>The domain string. For custom domains, this is the fully-qualified domain name, such as <code>auth.example.com</code>. For Amazon Cognito prefix domains, this is the prefix alone, such as <code>auth</code>.</p>
    pub fn domain(&self) -> ::std::option::Option<&str> {
        self.domain.as_deref()
    }
    /// <p>The Amazon S3 bucket where the static files for this domain are stored.</p>
    pub fn s3_bucket(&self) -> ::std::option::Option<&str> {
        self.s3_bucket.as_deref()
    }
    /// <p>The Amazon CloudFront endpoint that you use as the target of the alias that you set up with your Domain Name Service (DNS) provider.</p>
    pub fn cloud_front_distribution(&self) -> ::std::option::Option<&str> {
        self.cloud_front_distribution.as_deref()
    }
    /// <p>The app version.</p>
    pub fn version(&self) -> ::std::option::Option<&str> {
        self.version.as_deref()
    }
    /// <p>The domain status.</p>
    pub fn status(&self) -> ::std::option::Option<&crate::types::DomainStatusType> {
        self.status.as_ref()
    }
    /// <p>The configuration for a custom domain that hosts the sign-up and sign-in webpages for your application.</p>
    pub fn custom_domain_config(&self) -> ::std::option::Option<&crate::types::CustomDomainConfigType> {
        self.custom_domain_config.as_ref()
    }
}
impl DomainDescriptionType {
    /// Creates a new builder-style object to manufacture [`DomainDescriptionType`](crate::types::DomainDescriptionType).
    pub fn builder() -> crate::types::builders::DomainDescriptionTypeBuilder {
        crate::types::builders::DomainDescriptionTypeBuilder::default()
    }
}

/// A builder for [`DomainDescriptionType`](crate::types::DomainDescriptionType).
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct DomainDescriptionTypeBuilder {
    pub(crate) user_pool_id: ::std::option::Option<::std::string::String>,
    pub(crate) aws_account_id: ::std::option::Option<::std::string::String>,
    pub(crate) domain: ::std::option::Option<::std::string::String>,
    pub(crate) s3_bucket: ::std::option::Option<::std::string::String>,
    pub(crate) cloud_front_distribution: ::std::option::Option<::std::string::String>,
    pub(crate) version: ::std::option::Option<::std::string::String>,
    pub(crate) status: ::std::option::Option<crate::types::DomainStatusType>,
    pub(crate) custom_domain_config: ::std::option::Option<crate::types::CustomDomainConfigType>,
}
impl DomainDescriptionTypeBuilder {
    /// <p>The user pool ID.</p>
    pub fn user_pool_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.user_pool_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The user pool ID.</p>
    pub fn set_user_pool_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.user_pool_id = input;
        self
    }
    /// <p>The user pool ID.</p>
    pub fn get_user_pool_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.user_pool_id
    }
    /// <p>The Amazon Web Services ID for the user pool owner.</p>
    pub fn aws_account_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.aws_account_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The Amazon Web Services ID for the user pool owner.</p>
    pub fn set_aws_account_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.aws_account_id = input;
        self
    }
    /// <p>The Amazon Web Services ID for the user pool owner.</p>
    pub fn get_aws_account_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.aws_account_id
    }
    /// <p>The domain string. For custom domains, this is the fully-qualified domain name, such as <code>auth.example.com</code>. For Amazon Cognito prefix domains, this is the prefix alone, such as <code>auth</code>.</p>
    pub fn domain(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.domain = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The domain string. For custom domains, this is the fully-qualified domain name, such as <code>auth.example.com</code>. For Amazon Cognito prefix domains, this is the prefix alone, such as <code>auth</code>.</p>
    pub fn set_domain(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.domain = input;
        self
    }
    /// <p>The domain string. For custom domains, this is the fully-qualified domain name, such as <code>auth.example.com</code>. For Amazon Cognito prefix domains, this is the prefix alone, such as <code>auth</code>.</p>
    pub fn get_domain(&self) -> &::std::option::Option<::std::string::String> {
        &self.domain
    }
    /// <p>The Amazon S3 bucket where the static files for this domain are stored.</p>
    pub fn s3_bucket(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.s3_bucket = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The Amazon S3 bucket where the static files for this domain are stored.</p>
    pub fn set_s3_bucket(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.s3_bucket = input;
        self
    }
    /// <p>The Amazon S3 bucket where the static files for this domain are stored.</p>
    pub fn get_s3_bucket(&self) -> &::std::option::Option<::std::string::String> {
        &self.s3_bucket
    }
    /// <p>The Amazon CloudFront endpoint that you use as the target of the alias that you set up with your Domain Name Service (DNS) provider.</p>
    pub fn cloud_front_distribution(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.cloud_front_distribution = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The Amazon CloudFront endpoint that you use as the target of the alias that you set up with your Domain Name Service (DNS) provider.</p>
    pub fn set_cloud_front_distribution(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.cloud_front_distribution = input;
        self
    }
    /// <p>The Amazon CloudFront endpoint that you use as the target of the alias that you set up with your Domain Name Service (DNS) provider.</p>
    pub fn get_cloud_front_distribution(&self) -> &::std::option::Option<::std::string::String> {
        &self.cloud_front_distribution
    }
    /// <p>The app version.</p>
    pub fn version(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.version = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The app version.</p>
    pub fn set_version(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.version = input;
        self
    }
    /// <p>The app version.</p>
    pub fn get_version(&self) -> &::std::option::Option<::std::string::String> {
        &self.version
    }
    /// <p>The domain status.</p>
    pub fn status(mut self, input: crate::types::DomainStatusType) -> Self {
        self.status = ::std::option::Option::Some(input);
        self
    }
    /// <p>The domain status.</p>
    pub fn set_status(mut self, input: ::std::option::Option<crate::types::DomainStatusType>) -> Self {
        self.status = input;
        self
    }
    /// <p>The domain status.</p>
    pub fn get_status(&self) -> &::std::option::Option<crate::types::DomainStatusType> {
        &self.status
    }
    /// <p>The configuration for a custom domain that hosts the sign-up and sign-in webpages for your application.</p>
    pub fn custom_domain_config(mut self, input: crate::types::CustomDomainConfigType) -> Self {
        self.custom_domain_config = ::std::option::Option::Some(input);
        self
    }
    /// <p>The configuration for a custom domain that hosts the sign-up and sign-in webpages for your application.</p>
    pub fn set_custom_domain_config(mut self, input: ::std::option::Option<crate::types::CustomDomainConfigType>) -> Self {
        self.custom_domain_config = input;
        self
    }
    /// <p>The configuration for a custom domain that hosts the sign-up and sign-in webpages for your application.</p>
    pub fn get_custom_domain_config(&self) -> &::std::option::Option<crate::types::CustomDomainConfigType> {
        &self.custom_domain_config
    }
    /// Consumes the builder and constructs a [`DomainDescriptionType`](crate::types::DomainDescriptionType).
    pub fn build(self) -> crate::types::DomainDescriptionType {
        crate::types::DomainDescriptionType {
            user_pool_id: self.user_pool_id,
            aws_account_id: self.aws_account_id,
            domain: self.domain,
            s3_bucket: self.s3_bucket,
            cloud_front_distribution: self.cloud_front_distribution,
            version: self.version,
            status: self.status,
            custom_domain_config: self.custom_domain_config,
        }
    }
}