aws-sdk-s3outposts 0.27.0

AWS SDK for Amazon S3 on Outposts
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 CreateEndpointInput {
    /// <p>The ID of the Outposts. </p>
    #[doc(hidden)]
    pub outpost_id: std::option::Option<std::string::String>,
    /// <p>The ID of the subnet in the selected VPC. The endpoint subnet must belong to the Outpost that has Amazon S3 on Outposts provisioned.</p>
    #[doc(hidden)]
    pub subnet_id: std::option::Option<std::string::String>,
    /// <p>The ID of the security group to use with the endpoint.</p>
    #[doc(hidden)]
    pub security_group_id: std::option::Option<std::string::String>,
    /// <p>The type of access for the network connectivity for the Amazon S3 on Outposts endpoint. To use the Amazon Web Services VPC, choose <code>Private</code>. To use the endpoint with an on-premises network, choose <code>CustomerOwnedIp</code>. If you choose <code>CustomerOwnedIp</code>, you must also provide the customer-owned IP address pool (CoIP pool).</p> <note>
    /// <p> <code>Private</code> is the default access type value.</p>
    /// </note>
    #[doc(hidden)]
    pub access_type: std::option::Option<crate::types::EndpointAccessType>,
    /// <p>The ID of the customer-owned IPv4 address pool (CoIP pool) for the endpoint. IP addresses are allocated from this pool for the endpoint.</p>
    #[doc(hidden)]
    pub customer_owned_ipv4_pool: std::option::Option<std::string::String>,
}
impl CreateEndpointInput {
    /// <p>The ID of the Outposts. </p>
    pub fn outpost_id(&self) -> std::option::Option<&str> {
        self.outpost_id.as_deref()
    }
    /// <p>The ID of the subnet in the selected VPC. The endpoint subnet must belong to the Outpost that has Amazon S3 on Outposts provisioned.</p>
    pub fn subnet_id(&self) -> std::option::Option<&str> {
        self.subnet_id.as_deref()
    }
    /// <p>The ID of the security group to use with the endpoint.</p>
    pub fn security_group_id(&self) -> std::option::Option<&str> {
        self.security_group_id.as_deref()
    }
    /// <p>The type of access for the network connectivity for the Amazon S3 on Outposts endpoint. To use the Amazon Web Services VPC, choose <code>Private</code>. To use the endpoint with an on-premises network, choose <code>CustomerOwnedIp</code>. If you choose <code>CustomerOwnedIp</code>, you must also provide the customer-owned IP address pool (CoIP pool).</p> <note>
    /// <p> <code>Private</code> is the default access type value.</p>
    /// </note>
    pub fn access_type(&self) -> std::option::Option<&crate::types::EndpointAccessType> {
        self.access_type.as_ref()
    }
    /// <p>The ID of the customer-owned IPv4 address pool (CoIP pool) for the endpoint. IP addresses are allocated from this pool for the endpoint.</p>
    pub fn customer_owned_ipv4_pool(&self) -> std::option::Option<&str> {
        self.customer_owned_ipv4_pool.as_deref()
    }
}
impl CreateEndpointInput {
    /// Creates a new builder-style object to manufacture [`CreateEndpointInput`](crate::operation::create_endpoint::CreateEndpointInput).
    pub fn builder() -> crate::operation::create_endpoint::builders::CreateEndpointInputBuilder {
        crate::operation::create_endpoint::builders::CreateEndpointInputBuilder::default()
    }
}

/// A builder for [`CreateEndpointInput`](crate::operation::create_endpoint::CreateEndpointInput).
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct CreateEndpointInputBuilder {
    pub(crate) outpost_id: std::option::Option<std::string::String>,
    pub(crate) subnet_id: std::option::Option<std::string::String>,
    pub(crate) security_group_id: std::option::Option<std::string::String>,
    pub(crate) access_type: std::option::Option<crate::types::EndpointAccessType>,
    pub(crate) customer_owned_ipv4_pool: std::option::Option<std::string::String>,
}
impl CreateEndpointInputBuilder {
    /// <p>The ID of the Outposts. </p>
    pub fn outpost_id(mut self, input: impl Into<std::string::String>) -> Self {
        self.outpost_id = Some(input.into());
        self
    }
    /// <p>The ID of the Outposts. </p>
    pub fn set_outpost_id(mut self, input: std::option::Option<std::string::String>) -> Self {
        self.outpost_id = input;
        self
    }
    /// <p>The ID of the subnet in the selected VPC. The endpoint subnet must belong to the Outpost that has Amazon S3 on Outposts provisioned.</p>
    pub fn subnet_id(mut self, input: impl Into<std::string::String>) -> Self {
        self.subnet_id = Some(input.into());
        self
    }
    /// <p>The ID of the subnet in the selected VPC. The endpoint subnet must belong to the Outpost that has Amazon S3 on Outposts provisioned.</p>
    pub fn set_subnet_id(mut self, input: std::option::Option<std::string::String>) -> Self {
        self.subnet_id = input;
        self
    }
    /// <p>The ID of the security group to use with the endpoint.</p>
    pub fn security_group_id(mut self, input: impl Into<std::string::String>) -> Self {
        self.security_group_id = Some(input.into());
        self
    }
    /// <p>The ID of the security group to use with the endpoint.</p>
    pub fn set_security_group_id(
        mut self,
        input: std::option::Option<std::string::String>,
    ) -> Self {
        self.security_group_id = input;
        self
    }
    /// <p>The type of access for the network connectivity for the Amazon S3 on Outposts endpoint. To use the Amazon Web Services VPC, choose <code>Private</code>. To use the endpoint with an on-premises network, choose <code>CustomerOwnedIp</code>. If you choose <code>CustomerOwnedIp</code>, you must also provide the customer-owned IP address pool (CoIP pool).</p> <note>
    /// <p> <code>Private</code> is the default access type value.</p>
    /// </note>
    pub fn access_type(mut self, input: crate::types::EndpointAccessType) -> Self {
        self.access_type = Some(input);
        self
    }
    /// <p>The type of access for the network connectivity for the Amazon S3 on Outposts endpoint. To use the Amazon Web Services VPC, choose <code>Private</code>. To use the endpoint with an on-premises network, choose <code>CustomerOwnedIp</code>. If you choose <code>CustomerOwnedIp</code>, you must also provide the customer-owned IP address pool (CoIP pool).</p> <note>
    /// <p> <code>Private</code> is the default access type value.</p>
    /// </note>
    pub fn set_access_type(
        mut self,
        input: std::option::Option<crate::types::EndpointAccessType>,
    ) -> Self {
        self.access_type = input;
        self
    }
    /// <p>The ID of the customer-owned IPv4 address pool (CoIP pool) for the endpoint. IP addresses are allocated from this pool for the endpoint.</p>
    pub fn customer_owned_ipv4_pool(mut self, input: impl Into<std::string::String>) -> Self {
        self.customer_owned_ipv4_pool = Some(input.into());
        self
    }
    /// <p>The ID of the customer-owned IPv4 address pool (CoIP pool) for the endpoint. IP addresses are allocated from this pool for the endpoint.</p>
    pub fn set_customer_owned_ipv4_pool(
        mut self,
        input: std::option::Option<std::string::String>,
    ) -> Self {
        self.customer_owned_ipv4_pool = input;
        self
    }
    /// Consumes the builder and constructs a [`CreateEndpointInput`](crate::operation::create_endpoint::CreateEndpointInput).
    pub fn build(
        self,
    ) -> Result<
        crate::operation::create_endpoint::CreateEndpointInput,
        aws_smithy_http::operation::error::BuildError,
    > {
        Ok(crate::operation::create_endpoint::CreateEndpointInput {
            outpost_id: self.outpost_id,
            subnet_id: self.subnet_id,
            security_group_id: self.security_group_id,
            access_type: self.access_type,
            customer_owned_ipv4_pool: self.customer_owned_ipv4_pool,
        })
    }
}