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
// 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 AddRegionInput {
/// <p>The Amazon Resource Name (ARN) of the IAM Identity Center instance to replicate to the target Region.</p>
pub instance_arn: ::std::option::Option<::std::string::String>,
/// <p>The name of the Amazon Web Services Region to add to the IAM Identity Center instance. The Region name must be 1-32 characters long and follow the pattern of Amazon Web Services Region names (for example, us-east-1).</p>
pub region_name: ::std::option::Option<::std::string::String>,
}
impl AddRegionInput {
/// <p>The Amazon Resource Name (ARN) of the IAM Identity Center instance to replicate to the target Region.</p>
pub fn instance_arn(&self) -> ::std::option::Option<&str> {
self.instance_arn.as_deref()
}
/// <p>The name of the Amazon Web Services Region to add to the IAM Identity Center instance. The Region name must be 1-32 characters long and follow the pattern of Amazon Web Services Region names (for example, us-east-1).</p>
pub fn region_name(&self) -> ::std::option::Option<&str> {
self.region_name.as_deref()
}
}
impl AddRegionInput {
/// Creates a new builder-style object to manufacture [`AddRegionInput`](crate::operation::add_region::AddRegionInput).
pub fn builder() -> crate::operation::add_region::builders::AddRegionInputBuilder {
crate::operation::add_region::builders::AddRegionInputBuilder::default()
}
}
/// A builder for [`AddRegionInput`](crate::operation::add_region::AddRegionInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct AddRegionInputBuilder {
pub(crate) instance_arn: ::std::option::Option<::std::string::String>,
pub(crate) region_name: ::std::option::Option<::std::string::String>,
}
impl AddRegionInputBuilder {
/// <p>The Amazon Resource Name (ARN) of the IAM Identity Center instance to replicate to the target Region.</p>
/// This field is required.
pub fn instance_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.instance_arn = ::std::option::Option::Some(input.into());
self
}
/// <p>The Amazon Resource Name (ARN) of the IAM Identity Center instance to replicate to the target Region.</p>
pub fn set_instance_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.instance_arn = input;
self
}
/// <p>The Amazon Resource Name (ARN) of the IAM Identity Center instance to replicate to the target Region.</p>
pub fn get_instance_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.instance_arn
}
/// <p>The name of the Amazon Web Services Region to add to the IAM Identity Center instance. The Region name must be 1-32 characters long and follow the pattern of Amazon Web Services Region names (for example, us-east-1).</p>
/// This field is required.
pub fn region_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.region_name = ::std::option::Option::Some(input.into());
self
}
/// <p>The name of the Amazon Web Services Region to add to the IAM Identity Center instance. The Region name must be 1-32 characters long and follow the pattern of Amazon Web Services Region names (for example, us-east-1).</p>
pub fn set_region_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.region_name = input;
self
}
/// <p>The name of the Amazon Web Services Region to add to the IAM Identity Center instance. The Region name must be 1-32 characters long and follow the pattern of Amazon Web Services Region names (for example, us-east-1).</p>
pub fn get_region_name(&self) -> &::std::option::Option<::std::string::String> {
&self.region_name
}
/// Consumes the builder and constructs a [`AddRegionInput`](crate::operation::add_region::AddRegionInput).
pub fn build(self) -> ::std::result::Result<crate::operation::add_region::AddRegionInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::add_region::AddRegionInput {
instance_arn: self.instance_arn,
region_name: self.region_name,
})
}
}