aws-sdk-ssoadmin 1.102.0

AWS SDK for AWS Single Sign-On Admin
Documentation
// 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 RemoveRegionInput {
    /// <p>The Amazon Resource Name (ARN) of the IAM Identity Center instance.</p>
    pub instance_arn: ::std::option::Option<::std::string::String>,
    /// <p>The name of the Amazon Web Services Region to remove from 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). The primary Region cannot be removed.</p>
    pub region_name: ::std::option::Option<::std::string::String>,
}
impl RemoveRegionInput {
    /// <p>The Amazon Resource Name (ARN) of the IAM Identity Center instance.</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 remove from 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). The primary Region cannot be removed.</p>
    pub fn region_name(&self) -> ::std::option::Option<&str> {
        self.region_name.as_deref()
    }
}
impl RemoveRegionInput {
    /// Creates a new builder-style object to manufacture [`RemoveRegionInput`](crate::operation::remove_region::RemoveRegionInput).
    pub fn builder() -> crate::operation::remove_region::builders::RemoveRegionInputBuilder {
        crate::operation::remove_region::builders::RemoveRegionInputBuilder::default()
    }
}

/// A builder for [`RemoveRegionInput`](crate::operation::remove_region::RemoveRegionInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct RemoveRegionInputBuilder {
    pub(crate) instance_arn: ::std::option::Option<::std::string::String>,
    pub(crate) region_name: ::std::option::Option<::std::string::String>,
}
impl RemoveRegionInputBuilder {
    /// <p>The Amazon Resource Name (ARN) of the IAM Identity Center instance.</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.</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.</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 remove from 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). The primary Region cannot be removed.</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 remove from 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). The primary Region cannot be removed.</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 remove from 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). The primary Region cannot be removed.</p>
    pub fn get_region_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.region_name
    }
    /// Consumes the builder and constructs a [`RemoveRegionInput`](crate::operation::remove_region::RemoveRegionInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::remove_region::RemoveRegionInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::remove_region::RemoveRegionInput {
            instance_arn: self.instance_arn,
            region_name: self.region_name,
        })
    }
}