aws-sdk-s3control 1.109.0

AWS SDK for AWS S3 Control
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 GetAccessPointOutput {
    /// <p>The name of the specified access point.</p>
    pub name: ::std::option::Option<::std::string::String>,
    /// <p>The name of the bucket associated with the specified access point.</p>
    pub bucket: ::std::option::Option<::std::string::String>,
    /// <p>Indicates whether this access point allows access from the public internet. If <code>VpcConfiguration</code> is specified for this access point, then <code>NetworkOrigin</code> is <code>VPC</code>, and the access point doesn't allow access from the public internet. Otherwise, <code>NetworkOrigin</code> is <code>Internet</code>, and the access point allows access from the public internet, subject to the access point and bucket access policies.</p>
    /// <p>This will always be true for an Amazon S3 on Outposts access point</p>
    pub network_origin: ::std::option::Option<crate::types::NetworkOrigin>,
    /// <p>Contains the virtual private cloud (VPC) configuration for the specified access point.</p><note>
    /// <p>This element is empty if this access point is an Amazon S3 on Outposts access point that is used by other Amazon Web Services services.</p>
    /// </note>
    pub vpc_configuration: ::std::option::Option<crate::types::VpcConfiguration>,
    /// <p>The <code>PublicAccessBlock</code> configuration that you want to apply to this Amazon S3 account. You can enable the configuration options in any combination. For more information about when Amazon S3 considers a bucket or object public, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/access-control-block-public-access.html#access-control-block-public-access-policy-status">The Meaning of "Public"</a> in the <i>Amazon S3 User Guide</i>.</p>
    /// <p>This data type is not supported for Amazon S3 on Outposts.</p>
    pub public_access_block_configuration: ::std::option::Option<crate::types::PublicAccessBlockConfiguration>,
    /// <p>The date and time when the specified access point was created.</p>
    pub creation_date: ::std::option::Option<::aws_smithy_types::DateTime>,
    /// <p>The name or alias of the access point.</p>
    pub alias: ::std::option::Option<::std::string::String>,
    /// <p>The ARN of the access point.</p>
    pub access_point_arn: ::std::option::Option<::std::string::String>,
    /// <p>The VPC endpoint for the access point.</p>
    pub endpoints: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
    /// <p>The Amazon Web Services account ID associated with the S3 bucket associated with this access point.</p>
    pub bucket_account_id: ::std::option::Option<::std::string::String>,
    /// <p>The unique identifier for the data source of the access point.</p>
    pub data_source_id: ::std::option::Option<::std::string::String>,
    /// <p>The type of the data source that the access point is attached to.</p>
    pub data_source_type: ::std::option::Option<::std::string::String>,
    _request_id: Option<String>,
}
impl GetAccessPointOutput {
    /// <p>The name of the specified access point.</p>
    pub fn name(&self) -> ::std::option::Option<&str> {
        self.name.as_deref()
    }
    /// <p>The name of the bucket associated with the specified access point.</p>
    pub fn bucket(&self) -> ::std::option::Option<&str> {
        self.bucket.as_deref()
    }
    /// <p>Indicates whether this access point allows access from the public internet. If <code>VpcConfiguration</code> is specified for this access point, then <code>NetworkOrigin</code> is <code>VPC</code>, and the access point doesn't allow access from the public internet. Otherwise, <code>NetworkOrigin</code> is <code>Internet</code>, and the access point allows access from the public internet, subject to the access point and bucket access policies.</p>
    /// <p>This will always be true for an Amazon S3 on Outposts access point</p>
    pub fn network_origin(&self) -> ::std::option::Option<&crate::types::NetworkOrigin> {
        self.network_origin.as_ref()
    }
    /// <p>Contains the virtual private cloud (VPC) configuration for the specified access point.</p><note>
    /// <p>This element is empty if this access point is an Amazon S3 on Outposts access point that is used by other Amazon Web Services services.</p>
    /// </note>
    pub fn vpc_configuration(&self) -> ::std::option::Option<&crate::types::VpcConfiguration> {
        self.vpc_configuration.as_ref()
    }
    /// <p>The <code>PublicAccessBlock</code> configuration that you want to apply to this Amazon S3 account. You can enable the configuration options in any combination. For more information about when Amazon S3 considers a bucket or object public, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/access-control-block-public-access.html#access-control-block-public-access-policy-status">The Meaning of "Public"</a> in the <i>Amazon S3 User Guide</i>.</p>
    /// <p>This data type is not supported for Amazon S3 on Outposts.</p>
    pub fn public_access_block_configuration(&self) -> ::std::option::Option<&crate::types::PublicAccessBlockConfiguration> {
        self.public_access_block_configuration.as_ref()
    }
    /// <p>The date and time when the specified access point was created.</p>
    pub fn creation_date(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.creation_date.as_ref()
    }
    /// <p>The name or alias of the access point.</p>
    pub fn alias(&self) -> ::std::option::Option<&str> {
        self.alias.as_deref()
    }
    /// <p>The ARN of the access point.</p>
    pub fn access_point_arn(&self) -> ::std::option::Option<&str> {
        self.access_point_arn.as_deref()
    }
    /// <p>The VPC endpoint for the access point.</p>
    pub fn endpoints(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::string::String>> {
        self.endpoints.as_ref()
    }
    /// <p>The Amazon Web Services account ID associated with the S3 bucket associated with this access point.</p>
    pub fn bucket_account_id(&self) -> ::std::option::Option<&str> {
        self.bucket_account_id.as_deref()
    }
    /// <p>The unique identifier for the data source of the access point.</p>
    pub fn data_source_id(&self) -> ::std::option::Option<&str> {
        self.data_source_id.as_deref()
    }
    /// <p>The type of the data source that the access point is attached to.</p>
    pub fn data_source_type(&self) -> ::std::option::Option<&str> {
        self.data_source_type.as_deref()
    }
}
impl ::aws_types::request_id::RequestId for GetAccessPointOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl GetAccessPointOutput {
    /// Creates a new builder-style object to manufacture [`GetAccessPointOutput`](crate::operation::get_access_point::GetAccessPointOutput).
    pub fn builder() -> crate::operation::get_access_point::builders::GetAccessPointOutputBuilder {
        crate::operation::get_access_point::builders::GetAccessPointOutputBuilder::default()
    }
}

/// A builder for [`GetAccessPointOutput`](crate::operation::get_access_point::GetAccessPointOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetAccessPointOutputBuilder {
    pub(crate) name: ::std::option::Option<::std::string::String>,
    pub(crate) bucket: ::std::option::Option<::std::string::String>,
    pub(crate) network_origin: ::std::option::Option<crate::types::NetworkOrigin>,
    pub(crate) vpc_configuration: ::std::option::Option<crate::types::VpcConfiguration>,
    pub(crate) public_access_block_configuration: ::std::option::Option<crate::types::PublicAccessBlockConfiguration>,
    pub(crate) creation_date: ::std::option::Option<::aws_smithy_types::DateTime>,
    pub(crate) alias: ::std::option::Option<::std::string::String>,
    pub(crate) access_point_arn: ::std::option::Option<::std::string::String>,
    pub(crate) endpoints: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
    pub(crate) bucket_account_id: ::std::option::Option<::std::string::String>,
    pub(crate) data_source_id: ::std::option::Option<::std::string::String>,
    pub(crate) data_source_type: ::std::option::Option<::std::string::String>,
    _request_id: Option<String>,
}
impl GetAccessPointOutputBuilder {
    /// <p>The name of the specified access point.</p>
    pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name of the specified access point.</p>
    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.name = input;
        self
    }
    /// <p>The name of the specified access point.</p>
    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.name
    }
    /// <p>The name of the bucket associated with the specified access point.</p>
    pub fn bucket(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.bucket = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name of the bucket associated with the specified access point.</p>
    pub fn set_bucket(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.bucket = input;
        self
    }
    /// <p>The name of the bucket associated with the specified access point.</p>
    pub fn get_bucket(&self) -> &::std::option::Option<::std::string::String> {
        &self.bucket
    }
    /// <p>Indicates whether this access point allows access from the public internet. If <code>VpcConfiguration</code> is specified for this access point, then <code>NetworkOrigin</code> is <code>VPC</code>, and the access point doesn't allow access from the public internet. Otherwise, <code>NetworkOrigin</code> is <code>Internet</code>, and the access point allows access from the public internet, subject to the access point and bucket access policies.</p>
    /// <p>This will always be true for an Amazon S3 on Outposts access point</p>
    pub fn network_origin(mut self, input: crate::types::NetworkOrigin) -> Self {
        self.network_origin = ::std::option::Option::Some(input);
        self
    }
    /// <p>Indicates whether this access point allows access from the public internet. If <code>VpcConfiguration</code> is specified for this access point, then <code>NetworkOrigin</code> is <code>VPC</code>, and the access point doesn't allow access from the public internet. Otherwise, <code>NetworkOrigin</code> is <code>Internet</code>, and the access point allows access from the public internet, subject to the access point and bucket access policies.</p>
    /// <p>This will always be true for an Amazon S3 on Outposts access point</p>
    pub fn set_network_origin(mut self, input: ::std::option::Option<crate::types::NetworkOrigin>) -> Self {
        self.network_origin = input;
        self
    }
    /// <p>Indicates whether this access point allows access from the public internet. If <code>VpcConfiguration</code> is specified for this access point, then <code>NetworkOrigin</code> is <code>VPC</code>, and the access point doesn't allow access from the public internet. Otherwise, <code>NetworkOrigin</code> is <code>Internet</code>, and the access point allows access from the public internet, subject to the access point and bucket access policies.</p>
    /// <p>This will always be true for an Amazon S3 on Outposts access point</p>
    pub fn get_network_origin(&self) -> &::std::option::Option<crate::types::NetworkOrigin> {
        &self.network_origin
    }
    /// <p>Contains the virtual private cloud (VPC) configuration for the specified access point.</p><note>
    /// <p>This element is empty if this access point is an Amazon S3 on Outposts access point that is used by other Amazon Web Services services.</p>
    /// </note>
    pub fn vpc_configuration(mut self, input: crate::types::VpcConfiguration) -> Self {
        self.vpc_configuration = ::std::option::Option::Some(input);
        self
    }
    /// <p>Contains the virtual private cloud (VPC) configuration for the specified access point.</p><note>
    /// <p>This element is empty if this access point is an Amazon S3 on Outposts access point that is used by other Amazon Web Services services.</p>
    /// </note>
    pub fn set_vpc_configuration(mut self, input: ::std::option::Option<crate::types::VpcConfiguration>) -> Self {
        self.vpc_configuration = input;
        self
    }
    /// <p>Contains the virtual private cloud (VPC) configuration for the specified access point.</p><note>
    /// <p>This element is empty if this access point is an Amazon S3 on Outposts access point that is used by other Amazon Web Services services.</p>
    /// </note>
    pub fn get_vpc_configuration(&self) -> &::std::option::Option<crate::types::VpcConfiguration> {
        &self.vpc_configuration
    }
    /// <p>The <code>PublicAccessBlock</code> configuration that you want to apply to this Amazon S3 account. You can enable the configuration options in any combination. For more information about when Amazon S3 considers a bucket or object public, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/access-control-block-public-access.html#access-control-block-public-access-policy-status">The Meaning of "Public"</a> in the <i>Amazon S3 User Guide</i>.</p>
    /// <p>This data type is not supported for Amazon S3 on Outposts.</p>
    pub fn public_access_block_configuration(mut self, input: crate::types::PublicAccessBlockConfiguration) -> Self {
        self.public_access_block_configuration = ::std::option::Option::Some(input);
        self
    }
    /// <p>The <code>PublicAccessBlock</code> configuration that you want to apply to this Amazon S3 account. You can enable the configuration options in any combination. For more information about when Amazon S3 considers a bucket or object public, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/access-control-block-public-access.html#access-control-block-public-access-policy-status">The Meaning of "Public"</a> in the <i>Amazon S3 User Guide</i>.</p>
    /// <p>This data type is not supported for Amazon S3 on Outposts.</p>
    pub fn set_public_access_block_configuration(mut self, input: ::std::option::Option<crate::types::PublicAccessBlockConfiguration>) -> Self {
        self.public_access_block_configuration = input;
        self
    }
    /// <p>The <code>PublicAccessBlock</code> configuration that you want to apply to this Amazon S3 account. You can enable the configuration options in any combination. For more information about when Amazon S3 considers a bucket or object public, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/access-control-block-public-access.html#access-control-block-public-access-policy-status">The Meaning of "Public"</a> in the <i>Amazon S3 User Guide</i>.</p>
    /// <p>This data type is not supported for Amazon S3 on Outposts.</p>
    pub fn get_public_access_block_configuration(&self) -> &::std::option::Option<crate::types::PublicAccessBlockConfiguration> {
        &self.public_access_block_configuration
    }
    /// <p>The date and time when the specified access point was created.</p>
    pub fn creation_date(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.creation_date = ::std::option::Option::Some(input);
        self
    }
    /// <p>The date and time when the specified access point was created.</p>
    pub fn set_creation_date(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.creation_date = input;
        self
    }
    /// <p>The date and time when the specified access point was created.</p>
    pub fn get_creation_date(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.creation_date
    }
    /// <p>The name or alias of the access point.</p>
    pub fn alias(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.alias = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name or alias of the access point.</p>
    pub fn set_alias(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.alias = input;
        self
    }
    /// <p>The name or alias of the access point.</p>
    pub fn get_alias(&self) -> &::std::option::Option<::std::string::String> {
        &self.alias
    }
    /// <p>The ARN of the access point.</p>
    pub fn access_point_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.access_point_arn = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ARN of the access point.</p>
    pub fn set_access_point_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.access_point_arn = input;
        self
    }
    /// <p>The ARN of the access point.</p>
    pub fn get_access_point_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.access_point_arn
    }
    /// Adds a key-value pair to `endpoints`.
    ///
    /// To override the contents of this collection use [`set_endpoints`](Self::set_endpoints).
    ///
    /// <p>The VPC endpoint for the access point.</p>
    pub fn endpoints(mut self, k: impl ::std::convert::Into<::std::string::String>, v: impl ::std::convert::Into<::std::string::String>) -> Self {
        let mut hash_map = self.endpoints.unwrap_or_default();
        hash_map.insert(k.into(), v.into());
        self.endpoints = ::std::option::Option::Some(hash_map);
        self
    }
    /// <p>The VPC endpoint for the access point.</p>
    pub fn set_endpoints(mut self, input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>) -> Self {
        self.endpoints = input;
        self
    }
    /// <p>The VPC endpoint for the access point.</p>
    pub fn get_endpoints(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
        &self.endpoints
    }
    /// <p>The Amazon Web Services account ID associated with the S3 bucket associated with this access point.</p>
    pub fn bucket_account_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.bucket_account_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The Amazon Web Services account ID associated with the S3 bucket associated with this access point.</p>
    pub fn set_bucket_account_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.bucket_account_id = input;
        self
    }
    /// <p>The Amazon Web Services account ID associated with the S3 bucket associated with this access point.</p>
    pub fn get_bucket_account_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.bucket_account_id
    }
    /// <p>The unique identifier for the data source of the access point.</p>
    pub fn data_source_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.data_source_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The unique identifier for the data source of the access point.</p>
    pub fn set_data_source_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.data_source_id = input;
        self
    }
    /// <p>The unique identifier for the data source of the access point.</p>
    pub fn get_data_source_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.data_source_id
    }
    /// <p>The type of the data source that the access point is attached to.</p>
    pub fn data_source_type(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.data_source_type = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The type of the data source that the access point is attached to.</p>
    pub fn set_data_source_type(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.data_source_type = input;
        self
    }
    /// <p>The type of the data source that the access point is attached to.</p>
    pub fn get_data_source_type(&self) -> &::std::option::Option<::std::string::String> {
        &self.data_source_type
    }
    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
        self._request_id = Some(request_id.into());
        self
    }

    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
        self._request_id = request_id;
        self
    }
    /// Consumes the builder and constructs a [`GetAccessPointOutput`](crate::operation::get_access_point::GetAccessPointOutput).
    pub fn build(self) -> crate::operation::get_access_point::GetAccessPointOutput {
        crate::operation::get_access_point::GetAccessPointOutput {
            name: self.name,
            bucket: self.bucket,
            network_origin: self.network_origin,
            vpc_configuration: self.vpc_configuration,
            public_access_block_configuration: self.public_access_block_configuration,
            creation_date: self.creation_date,
            alias: self.alias,
            access_point_arn: self.access_point_arn,
            endpoints: self.endpoints,
            bucket_account_id: self.bucket_account_id,
            data_source_id: self.data_source_id,
            data_source_type: self.data_source_type,
            _request_id: self._request_id,
        }
    }
}