pub struct Builder { /* private fields */ }
Expand description

A builder for PutBucketAclInput.

Implementations§

The canned ACL to apply to the bucket.

Examples found in repository?
src/client.rs (line 10972)
10971
10972
10973
10974
        pub fn acl(mut self, input: crate::model::BucketCannedAcl) -> Self {
            self.inner = self.inner.acl(input);
            self
        }

The canned ACL to apply to the bucket.

Examples found in repository?
src/client.rs (line 10980)
10976
10977
10978
10979
10980
10981
10982
        pub fn set_acl(
            mut self,
            input: std::option::Option<crate::model::BucketCannedAcl>,
        ) -> Self {
            self.inner = self.inner.set_acl(input);
            self
        }

Contains the elements that set the ACL permissions for an object per grantee.

Examples found in repository?
src/client.rs (line 10985)
10984
10985
10986
10987
        pub fn access_control_policy(mut self, input: crate::model::AccessControlPolicy) -> Self {
            self.inner = self.inner.access_control_policy(input);
            self
        }

Contains the elements that set the ACL permissions for an object per grantee.

Examples found in repository?
src/client.rs (line 10993)
10989
10990
10991
10992
10993
10994
10995
        pub fn set_access_control_policy(
            mut self,
            input: std::option::Option<crate::model::AccessControlPolicy>,
        ) -> Self {
            self.inner = self.inner.set_access_control_policy(input);
            self
        }

The bucket to which to apply the ACL.

Examples found in repository?
src/client.rs (line 10998)
10997
10998
10999
11000
        pub fn bucket(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.bucket(input.into());
            self
        }

The bucket to which to apply the ACL.

Examples found in repository?
src/client.rs (line 11003)
11002
11003
11004
11005
        pub fn set_bucket(mut self, input: std::option::Option<std::string::String>) -> Self {
            self.inner = self.inner.set_bucket(input);
            self
        }

The base64-encoded 128-bit MD5 digest of the data. This header must be used as a message integrity check to verify that the request body was not corrupted in transit. For more information, go to RFC 1864.

For requests made using the Amazon Web Services Command Line Interface (CLI) or Amazon Web Services SDKs, this field is calculated automatically.

Examples found in repository?
src/client.rs (line 11009)
11008
11009
11010
11011
        pub fn content_md5(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.content_md5(input.into());
            self
        }

The base64-encoded 128-bit MD5 digest of the data. This header must be used as a message integrity check to verify that the request body was not corrupted in transit. For more information, go to RFC 1864.

For requests made using the Amazon Web Services Command Line Interface (CLI) or Amazon Web Services SDKs, this field is calculated automatically.

Examples found in repository?
src/client.rs (line 11015)
11014
11015
11016
11017
        pub fn set_content_md5(mut self, input: std::option::Option<std::string::String>) -> Self {
            self.inner = self.inner.set_content_md5(input);
            self
        }

Indicates the algorithm used to create the checksum for the object when using the SDK. This header will not provide any additional functionality if not using the SDK. When sending this header, there must be a corresponding x-amz-checksum or x-amz-trailer header sent. Otherwise, Amazon S3 fails the request with the HTTP status code 400 Bad Request. For more information, see Checking object integrity in the Amazon S3 User Guide.

If you provide an individual checksum, Amazon S3 ignores any provided ChecksumAlgorithm parameter.

Examples found in repository?
src/client.rs (line 11021)
11020
11021
11022
11023
        pub fn checksum_algorithm(mut self, input: crate::model::ChecksumAlgorithm) -> Self {
            self.inner = self.inner.checksum_algorithm(input);
            self
        }

Indicates the algorithm used to create the checksum for the object when using the SDK. This header will not provide any additional functionality if not using the SDK. When sending this header, there must be a corresponding x-amz-checksum or x-amz-trailer header sent. Otherwise, Amazon S3 fails the request with the HTTP status code 400 Bad Request. For more information, see Checking object integrity in the Amazon S3 User Guide.

If you provide an individual checksum, Amazon S3 ignores any provided ChecksumAlgorithm parameter.

Examples found in repository?
src/client.rs (line 11030)
11026
11027
11028
11029
11030
11031
11032
        pub fn set_checksum_algorithm(
            mut self,
            input: std::option::Option<crate::model::ChecksumAlgorithm>,
        ) -> Self {
            self.inner = self.inner.set_checksum_algorithm(input);
            self
        }

Allows grantee the read, write, read ACP, and write ACP permissions on the bucket.

Examples found in repository?
src/client.rs (line 11035)
11034
11035
11036
11037
        pub fn grant_full_control(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.grant_full_control(input.into());
            self
        }

Allows grantee the read, write, read ACP, and write ACP permissions on the bucket.

Examples found in repository?
src/client.rs (line 11043)
11039
11040
11041
11042
11043
11044
11045
        pub fn set_grant_full_control(
            mut self,
            input: std::option::Option<std::string::String>,
        ) -> Self {
            self.inner = self.inner.set_grant_full_control(input);
            self
        }

Allows grantee to list the objects in the bucket.

Examples found in repository?
src/client.rs (line 11048)
11047
11048
11049
11050
        pub fn grant_read(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.grant_read(input.into());
            self
        }

Allows grantee to list the objects in the bucket.

Examples found in repository?
src/client.rs (line 11053)
11052
11053
11054
11055
        pub fn set_grant_read(mut self, input: std::option::Option<std::string::String>) -> Self {
            self.inner = self.inner.set_grant_read(input);
            self
        }

Allows grantee to read the bucket ACL.

Examples found in repository?
src/client.rs (line 11058)
11057
11058
11059
11060
        pub fn grant_read_acp(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.grant_read_acp(input.into());
            self
        }

Allows grantee to read the bucket ACL.

Examples found in repository?
src/client.rs (line 11066)
11062
11063
11064
11065
11066
11067
11068
        pub fn set_grant_read_acp(
            mut self,
            input: std::option::Option<std::string::String>,
        ) -> Self {
            self.inner = self.inner.set_grant_read_acp(input);
            self
        }

Allows grantee to create new objects in the bucket.

For the bucket and object owners of existing objects, also allows deletions and overwrites of those objects.

Examples found in repository?
src/client.rs (line 11072)
11071
11072
11073
11074
        pub fn grant_write(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.grant_write(input.into());
            self
        }

Allows grantee to create new objects in the bucket.

For the bucket and object owners of existing objects, also allows deletions and overwrites of those objects.

Examples found in repository?
src/client.rs (line 11078)
11077
11078
11079
11080
        pub fn set_grant_write(mut self, input: std::option::Option<std::string::String>) -> Self {
            self.inner = self.inner.set_grant_write(input);
            self
        }

Allows grantee to write the ACL for the applicable bucket.

Examples found in repository?
src/client.rs (line 11083)
11082
11083
11084
11085
        pub fn grant_write_acp(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.grant_write_acp(input.into());
            self
        }

Allows grantee to write the ACL for the applicable bucket.

Examples found in repository?
src/client.rs (line 11091)
11087
11088
11089
11090
11091
11092
11093
        pub fn set_grant_write_acp(
            mut self,
            input: std::option::Option<std::string::String>,
        ) -> Self {
            self.inner = self.inner.set_grant_write_acp(input);
            self
        }

The account ID of the expected bucket owner. If the bucket is owned by a different account, the request fails with the HTTP status code 403 Forbidden (access denied).

Examples found in repository?
src/client.rs (line 11096)
11095
11096
11097
11098
        pub fn expected_bucket_owner(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.expected_bucket_owner(input.into());
            self
        }

The account ID of the expected bucket owner. If the bucket is owned by a different account, the request fails with the HTTP status code 403 Forbidden (access denied).

Examples found in repository?
src/client.rs (line 11104)
11100
11101
11102
11103
11104
11105
11106
        pub fn set_expected_bucket_owner(
            mut self,
            input: std::option::Option<std::string::String>,
        ) -> Self {
            self.inner = self.inner.set_expected_bucket_owner(input);
            self
        }

Consumes the builder and constructs a PutBucketAclInput.

Examples found in repository?
src/client.rs (line 10939)
10927
10928
10929
10930
10931
10932
10933
10934
10935
10936
10937
10938
10939
10940
10941
10942
10943
10944
10945
10946
10947
10948
10949
10950
10951
10952
10953
10954
10955
10956
10957
10958
10959
10960
10961
10962
10963
10964
10965
10966
10967
10968
10969
        pub async fn customize(
            self,
        ) -> std::result::Result<
            crate::operation::customize::CustomizableOperation<
                crate::operation::PutBucketAcl,
                aws_http::retry::AwsResponseRetryClassifier,
            >,
            aws_smithy_http::result::SdkError<crate::error::PutBucketAclError>,
        > {
            let handle = self.handle.clone();
            let operation = self
                .inner
                .build()
                .map_err(aws_smithy_http::result::SdkError::construction_failure)?
                .make_operation(&handle.conf)
                .await
                .map_err(aws_smithy_http::result::SdkError::construction_failure)?;
            Ok(crate::operation::customize::CustomizableOperation { handle, operation })
        }

        /// Sends the request and returns the response.
        ///
        /// If an error occurs, an `SdkError` will be returned with additional details that
        /// can be matched against.
        ///
        /// By default, any retryable failures will be retried twice. Retry behavior
        /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
        /// set when configuring the client.
        pub async fn send(
            self,
        ) -> std::result::Result<
            crate::output::PutBucketAclOutput,
            aws_smithy_http::result::SdkError<crate::error::PutBucketAclError>,
        > {
            let op = self
                .inner
                .build()
                .map_err(aws_smithy_http::result::SdkError::construction_failure)?
                .make_operation(&self.handle.conf)
                .await
                .map_err(aws_smithy_http::result::SdkError::construction_failure)?;
            self.handle.client.call(op).await
        }

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
Returns the “default value” for a type. Read more
This method tests for self and other values to be equal, and is used by ==. Read more
This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Should always be Self
The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.
Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more