aws_sdk_s3/operation/get_object_attributes/
builders.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2pub use crate::operation::get_object_attributes::_get_object_attributes_output::GetObjectAttributesOutputBuilder;
3
4pub use crate::operation::get_object_attributes::_get_object_attributes_input::GetObjectAttributesInputBuilder;
5
6impl crate::operation::get_object_attributes::builders::GetObjectAttributesInputBuilder {
7    /// Sends a request with this input using the given client.
8    pub async fn send_with(
9        self,
10        client: &crate::Client,
11    ) -> ::std::result::Result<
12        crate::operation::get_object_attributes::GetObjectAttributesOutput,
13        ::aws_smithy_runtime_api::client::result::SdkError<
14            crate::operation::get_object_attributes::GetObjectAttributesError,
15            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
16        >,
17    > {
18        let mut fluent_builder = client.get_object_attributes();
19        fluent_builder.inner = self;
20        fluent_builder.send().await
21    }
22}
23/// Fluent builder constructing a request to `GetObjectAttributes`.
24///
25/// <p>Retrieves all the metadata from an object without returning the object itself. This operation is useful if you're interested only in an object's metadata.</p>
26/// <p><code>GetObjectAttributes</code> combines the functionality of <code>HeadObject</code> and <code>ListParts</code>. All of the data returned with each of those individual calls can be returned with a single call to <code>GetObjectAttributes</code>.</p><note>
27/// <p><b>Directory buckets</b> - For directory buckets, you must make requests for this API operation to the Zonal endpoint. These endpoints support virtual-hosted-style requests in the format <code>https://<i>bucket_name</i>.s3express-<i>az_id</i>.<i>region</i>.amazonaws.com/<i>key-name</i> </code>. Path-style requests are not supported. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html">Regional and Zonal endpoints</a> in the <i>Amazon S3 User Guide</i>.</p>
28/// </note>
29/// <dl>
30/// <dt>
31/// Permissions
32/// </dt>
33/// <dd>
34/// <ul>
35/// <li>
36/// <p><b>General purpose bucket permissions</b> - To use <code>GetObjectAttributes</code>, you must have READ access to the object. The permissions that you need to use this operation with depend on whether the bucket is versioned. If the bucket is versioned, you need both the <code>s3:GetObjectVersion</code> and <code>s3:GetObjectVersionAttributes</code> permissions for this operation. If the bucket is not versioned, you need the <code>s3:GetObject</code> and <code>s3:GetObjectAttributes</code> permissions. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/using-with-s3-actions.html">Specifying Permissions in a Policy</a> in the <i>Amazon S3 User Guide</i>. If the object that you request does not exist, the error Amazon S3 returns depends on whether you also have the <code>s3:ListBucket</code> permission.</p>
37/// <ul>
38/// <li>
39/// <p>If you have the <code>s3:ListBucket</code> permission on the bucket, Amazon S3 returns an HTTP status code <code>404 Not Found</code> ("no such key") error.</p></li>
40/// <li>
41/// <p>If you don't have the <code>s3:ListBucket</code> permission, Amazon S3 returns an HTTP status code <code>403 Forbidden</code> ("access denied") error.</p></li>
42/// </ul></li>
43/// <li>
44/// <p><b>Directory bucket permissions</b> - To grant access to this API operation on a directory bucket, we recommend that you use the <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html"> <code>CreateSession</code> </a> API operation for session-based authorization. Specifically, you grant the <code>s3express:CreateSession</code> permission to the directory bucket in a bucket policy or an IAM identity-based policy. Then, you make the <code>CreateSession</code> API call on the bucket to obtain a session token. With the session token in your request header, you can make API requests to this operation. After the session token expires, you make another <code>CreateSession</code> API call to generate a new session token for use. Amazon Web Services CLI or SDKs create session and refresh the session token automatically to avoid service interruptions when a session expires. For more information about authorization, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html"> <code>CreateSession</code> </a>.</p></li>
45/// </ul>
46/// </dd>
47/// <dt>
48/// Encryption
49/// </dt>
50/// <dd>
51/// <note>
52/// <p>Encryption request headers, like <code>x-amz-server-side-encryption</code>, should not be sent for <code>HEAD</code> requests if your object uses server-side encryption with Key Management Service (KMS) keys (SSE-KMS), dual-layer server-side encryption with Amazon Web Services KMS keys (DSSE-KMS), or server-side encryption with Amazon S3 managed encryption keys (SSE-S3). The <code>x-amz-server-side-encryption</code> header is used when you <code>PUT</code> an object to S3 and want to specify the encryption method. If you include this header in a <code>GET</code> request for an object that uses these types of keys, you’ll get an HTTP <code>400 Bad Request</code> error. It's because the encryption method can't be changed when you retrieve the object.</p>
53/// </note>
54/// <p>If you encrypt an object by using server-side encryption with customer-provided encryption keys (SSE-C) when you store the object in Amazon S3, then when you retrieve the metadata from the object, you must use the following headers to provide the encryption key for the server to be able to retrieve the object's metadata. The headers are:</p>
55/// <ul>
56/// <li>
57/// <p><code>x-amz-server-side-encryption-customer-algorithm</code></p></li>
58/// <li>
59/// <p><code>x-amz-server-side-encryption-customer-key</code></p></li>
60/// <li>
61/// <p><code>x-amz-server-side-encryption-customer-key-MD5</code></p></li>
62/// </ul>
63/// <p>For more information about SSE-C, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html">Server-Side Encryption (Using Customer-Provided Encryption Keys)</a> in the <i>Amazon S3 User Guide</i>.</p><note>
64/// <p><b>Directory bucket permissions</b> - For directory buckets, only server-side encryption with Amazon S3 managed keys (SSE-S3) (<code>AES256</code>) is supported.</p>
65/// </note>
66/// </dd>
67/// <dt>
68/// Versioning
69/// </dt>
70/// <dd>
71/// <p><b>Directory buckets</b> - S3 Versioning isn't enabled and supported for directory buckets. For this API operation, only the <code>null</code> value of the version ID is supported by directory buckets. You can only specify <code>null</code> to the <code>versionId</code> query parameter in the request.</p>
72/// </dd>
73/// <dt>
74/// Conditional request headers
75/// </dt>
76/// <dd>
77/// <p>Consider the following when using request headers:</p>
78/// <ul>
79/// <li>
80/// <p>If both of the <code>If-Match</code> and <code>If-Unmodified-Since</code> headers are present in the request as follows, then Amazon S3 returns the HTTP status code <code>200 OK</code> and the data requested:</p>
81/// <ul>
82/// <li>
83/// <p><code>If-Match</code> condition evaluates to <code>true</code>.</p></li>
84/// <li>
85/// <p><code>If-Unmodified-Since</code> condition evaluates to <code>false</code>.</p></li>
86/// </ul>
87/// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p></li>
88/// <li>
89/// <p>If both of the <code>If-None-Match</code> and <code>If-Modified-Since</code> headers are present in the request as follows, then Amazon S3 returns the HTTP status code <code>304 Not Modified</code>:</p>
90/// <ul>
91/// <li>
92/// <p><code>If-None-Match</code> condition evaluates to <code>false</code>.</p></li>
93/// <li>
94/// <p><code>If-Modified-Since</code> condition evaluates to <code>true</code>.</p></li>
95/// </ul>
96/// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p></li>
97/// </ul>
98/// </dd>
99/// <dt>
100/// HTTP Host header syntax
101/// </dt>
102/// <dd>
103/// <p><b>Directory buckets </b> - The HTTP Host header syntax is <code> <i>Bucket_name</i>.s3express-<i>az_id</i>.<i>region</i>.amazonaws.com</code>.</p>
104/// </dd>
105/// </dl>
106/// <p>The following actions are related to <code>GetObjectAttributes</code>:</p>
107/// <ul>
108/// <li>
109/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html">GetObject</a></p></li>
110/// <li>
111/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAcl.html">GetObjectAcl</a></p></li>
112/// <li>
113/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectLegalHold.html">GetObjectLegalHold</a></p></li>
114/// <li>
115/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectLockConfiguration.html">GetObjectLockConfiguration</a></p></li>
116/// <li>
117/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectRetention.html">GetObjectRetention</a></p></li>
118/// <li>
119/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectTagging.html">GetObjectTagging</a></p></li>
120/// <li>
121/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_HeadObject.html">HeadObject</a></p></li>
122/// <li>
123/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html">ListParts</a></p></li>
124/// </ul>
125#[derive(::std::clone::Clone, ::std::fmt::Debug)]
126pub struct GetObjectAttributesFluentBuilder {
127    handle: ::std::sync::Arc<crate::client::Handle>,
128    inner: crate::operation::get_object_attributes::builders::GetObjectAttributesInputBuilder,
129    config_override: ::std::option::Option<crate::config::Builder>,
130}
131impl
132    crate::client::customize::internal::CustomizableSend<
133        crate::operation::get_object_attributes::GetObjectAttributesOutput,
134        crate::operation::get_object_attributes::GetObjectAttributesError,
135    > for GetObjectAttributesFluentBuilder
136{
137    fn send(
138        self,
139        config_override: crate::config::Builder,
140    ) -> crate::client::customize::internal::BoxFuture<
141        crate::client::customize::internal::SendResult<
142            crate::operation::get_object_attributes::GetObjectAttributesOutput,
143            crate::operation::get_object_attributes::GetObjectAttributesError,
144        >,
145    > {
146        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
147    }
148}
149impl GetObjectAttributesFluentBuilder {
150    /// Creates a new `GetObjectAttributesFluentBuilder`.
151    pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
152        Self {
153            handle,
154            inner: ::std::default::Default::default(),
155            config_override: ::std::option::Option::None,
156        }
157    }
158    /// Access the GetObjectAttributes as a reference.
159    pub fn as_input(&self) -> &crate::operation::get_object_attributes::builders::GetObjectAttributesInputBuilder {
160        &self.inner
161    }
162    /// Sends the request and returns the response.
163    ///
164    /// If an error occurs, an `SdkError` will be returned with additional details that
165    /// can be matched against.
166    ///
167    /// By default, any retryable failures will be retried twice. Retry behavior
168    /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
169    /// set when configuring the client.
170    pub async fn send(
171        self,
172    ) -> ::std::result::Result<
173        crate::operation::get_object_attributes::GetObjectAttributesOutput,
174        ::aws_smithy_runtime_api::client::result::SdkError<
175            crate::operation::get_object_attributes::GetObjectAttributesError,
176            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
177        >,
178    > {
179        let input = self
180            .inner
181            .build()
182            .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
183        let runtime_plugins = crate::operation::get_object_attributes::GetObjectAttributes::operation_runtime_plugins(
184            self.handle.runtime_plugins.clone(),
185            &self.handle.conf,
186            self.config_override,
187        );
188        crate::operation::get_object_attributes::GetObjectAttributes::orchestrate(&runtime_plugins, input).await
189    }
190
191    /// Consumes this builder, creating a customizable operation that can be modified before being sent.
192    pub fn customize(
193        self,
194    ) -> crate::client::customize::CustomizableOperation<
195        crate::operation::get_object_attributes::GetObjectAttributesOutput,
196        crate::operation::get_object_attributes::GetObjectAttributesError,
197        Self,
198    > {
199        crate::client::customize::CustomizableOperation::new(self)
200    }
201    pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
202        self.set_config_override(::std::option::Option::Some(config_override.into()));
203        self
204    }
205
206    pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
207        self.config_override = config_override;
208        self
209    }
210    /// <p>The name of the bucket that contains the object.</p>
211    /// <p><b>Directory buckets</b> - When you use this operation with a directory bucket, you must use virtual-hosted-style requests in the format <code> <i>Bucket_name</i>.s3express-<i>az_id</i>.<i>region</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Availability Zone. Bucket names must follow the format <code> <i>bucket_base_name</i>--<i>az-id</i>--x-s3</code> (for example, <code> <i>DOC-EXAMPLE-BUCKET</i>--<i>usw2-az1</i>--x-s3</code>). For information about bucket naming restrictions, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-bucket-naming-rules.html">Directory bucket naming rules</a> in the <i>Amazon S3 User Guide</i>.</p>
212    /// <p><b>Access points</b> - When you use this action with an access point, you must provide the alias of the access point in place of the bucket name or specify the access point ARN. When using the access point ARN, you must direct requests to the access point hostname. The access point hostname takes the form <i>AccessPointName</i>-<i>AccountId</i>.s3-accesspoint.<i>Region</i>.amazonaws.com. When using this action with an access point through the Amazon Web Services SDKs, you provide the access point ARN in place of the bucket name. For more information about access point ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-access-points.html">Using access points</a> in the <i>Amazon S3 User Guide</i>.</p><note>
213    /// <p>Access points and Object Lambda access points are not supported by directory buckets.</p>
214    /// </note>
215    /// <p><b>S3 on Outposts</b> - When you use this action with Amazon S3 on Outposts, you must direct requests to the S3 on Outposts hostname. The S3 on Outposts hostname takes the form <code> <i>AccessPointName</i>-<i>AccountId</i>.<i>outpostID</i>.s3-outposts.<i>Region</i>.amazonaws.com</code>. When you use this action with S3 on Outposts through the Amazon Web Services SDKs, you provide the Outposts access point ARN in place of the bucket name. For more information about S3 on Outposts ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/S3onOutposts.html">What is S3 on Outposts?</a> in the <i>Amazon S3 User Guide</i>.</p>
216    pub fn bucket(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
217        self.inner = self.inner.bucket(input.into());
218        self
219    }
220    /// <p>The name of the bucket that contains the object.</p>
221    /// <p><b>Directory buckets</b> - When you use this operation with a directory bucket, you must use virtual-hosted-style requests in the format <code> <i>Bucket_name</i>.s3express-<i>az_id</i>.<i>region</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Availability Zone. Bucket names must follow the format <code> <i>bucket_base_name</i>--<i>az-id</i>--x-s3</code> (for example, <code> <i>DOC-EXAMPLE-BUCKET</i>--<i>usw2-az1</i>--x-s3</code>). For information about bucket naming restrictions, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-bucket-naming-rules.html">Directory bucket naming rules</a> in the <i>Amazon S3 User Guide</i>.</p>
222    /// <p><b>Access points</b> - When you use this action with an access point, you must provide the alias of the access point in place of the bucket name or specify the access point ARN. When using the access point ARN, you must direct requests to the access point hostname. The access point hostname takes the form <i>AccessPointName</i>-<i>AccountId</i>.s3-accesspoint.<i>Region</i>.amazonaws.com. When using this action with an access point through the Amazon Web Services SDKs, you provide the access point ARN in place of the bucket name. For more information about access point ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-access-points.html">Using access points</a> in the <i>Amazon S3 User Guide</i>.</p><note>
223    /// <p>Access points and Object Lambda access points are not supported by directory buckets.</p>
224    /// </note>
225    /// <p><b>S3 on Outposts</b> - When you use this action with Amazon S3 on Outposts, you must direct requests to the S3 on Outposts hostname. The S3 on Outposts hostname takes the form <code> <i>AccessPointName</i>-<i>AccountId</i>.<i>outpostID</i>.s3-outposts.<i>Region</i>.amazonaws.com</code>. When you use this action with S3 on Outposts through the Amazon Web Services SDKs, you provide the Outposts access point ARN in place of the bucket name. For more information about S3 on Outposts ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/S3onOutposts.html">What is S3 on Outposts?</a> in the <i>Amazon S3 User Guide</i>.</p>
226    pub fn set_bucket(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
227        self.inner = self.inner.set_bucket(input);
228        self
229    }
230    /// <p>The name of the bucket that contains the object.</p>
231    /// <p><b>Directory buckets</b> - When you use this operation with a directory bucket, you must use virtual-hosted-style requests in the format <code> <i>Bucket_name</i>.s3express-<i>az_id</i>.<i>region</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Availability Zone. Bucket names must follow the format <code> <i>bucket_base_name</i>--<i>az-id</i>--x-s3</code> (for example, <code> <i>DOC-EXAMPLE-BUCKET</i>--<i>usw2-az1</i>--x-s3</code>). For information about bucket naming restrictions, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-bucket-naming-rules.html">Directory bucket naming rules</a> in the <i>Amazon S3 User Guide</i>.</p>
232    /// <p><b>Access points</b> - When you use this action with an access point, you must provide the alias of the access point in place of the bucket name or specify the access point ARN. When using the access point ARN, you must direct requests to the access point hostname. The access point hostname takes the form <i>AccessPointName</i>-<i>AccountId</i>.s3-accesspoint.<i>Region</i>.amazonaws.com. When using this action with an access point through the Amazon Web Services SDKs, you provide the access point ARN in place of the bucket name. For more information about access point ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-access-points.html">Using access points</a> in the <i>Amazon S3 User Guide</i>.</p><note>
233    /// <p>Access points and Object Lambda access points are not supported by directory buckets.</p>
234    /// </note>
235    /// <p><b>S3 on Outposts</b> - When you use this action with Amazon S3 on Outposts, you must direct requests to the S3 on Outposts hostname. The S3 on Outposts hostname takes the form <code> <i>AccessPointName</i>-<i>AccountId</i>.<i>outpostID</i>.s3-outposts.<i>Region</i>.amazonaws.com</code>. When you use this action with S3 on Outposts through the Amazon Web Services SDKs, you provide the Outposts access point ARN in place of the bucket name. For more information about S3 on Outposts ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/S3onOutposts.html">What is S3 on Outposts?</a> in the <i>Amazon S3 User Guide</i>.</p>
236    pub fn get_bucket(&self) -> &::std::option::Option<::std::string::String> {
237        self.inner.get_bucket()
238    }
239    /// <p>The object key.</p>
240    pub fn key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
241        self.inner = self.inner.key(input.into());
242        self
243    }
244    /// <p>The object key.</p>
245    pub fn set_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
246        self.inner = self.inner.set_key(input);
247        self
248    }
249    /// <p>The object key.</p>
250    pub fn get_key(&self) -> &::std::option::Option<::std::string::String> {
251        self.inner.get_key()
252    }
253    /// <p>The version ID used to reference a specific version of the object.</p><note>
254    /// <p>S3 Versioning isn't enabled and supported for directory buckets. For this API operation, only the <code>null</code> value of the version ID is supported by directory buckets. You can only specify <code>null</code> to the <code>versionId</code> query parameter in the request.</p>
255    /// </note>
256    pub fn version_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
257        self.inner = self.inner.version_id(input.into());
258        self
259    }
260    /// <p>The version ID used to reference a specific version of the object.</p><note>
261    /// <p>S3 Versioning isn't enabled and supported for directory buckets. For this API operation, only the <code>null</code> value of the version ID is supported by directory buckets. You can only specify <code>null</code> to the <code>versionId</code> query parameter in the request.</p>
262    /// </note>
263    pub fn set_version_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
264        self.inner = self.inner.set_version_id(input);
265        self
266    }
267    /// <p>The version ID used to reference a specific version of the object.</p><note>
268    /// <p>S3 Versioning isn't enabled and supported for directory buckets. For this API operation, only the <code>null</code> value of the version ID is supported by directory buckets. You can only specify <code>null</code> to the <code>versionId</code> query parameter in the request.</p>
269    /// </note>
270    pub fn get_version_id(&self) -> &::std::option::Option<::std::string::String> {
271        self.inner.get_version_id()
272    }
273    /// <p>Sets the maximum number of parts to return.</p>
274    pub fn max_parts(mut self, input: i32) -> Self {
275        self.inner = self.inner.max_parts(input);
276        self
277    }
278    /// <p>Sets the maximum number of parts to return.</p>
279    pub fn set_max_parts(mut self, input: ::std::option::Option<i32>) -> Self {
280        self.inner = self.inner.set_max_parts(input);
281        self
282    }
283    /// <p>Sets the maximum number of parts to return.</p>
284    pub fn get_max_parts(&self) -> &::std::option::Option<i32> {
285        self.inner.get_max_parts()
286    }
287    /// <p>Specifies the part after which listing should begin. Only parts with higher part numbers will be listed.</p>
288    pub fn part_number_marker(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
289        self.inner = self.inner.part_number_marker(input.into());
290        self
291    }
292    /// <p>Specifies the part after which listing should begin. Only parts with higher part numbers will be listed.</p>
293    pub fn set_part_number_marker(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
294        self.inner = self.inner.set_part_number_marker(input);
295        self
296    }
297    /// <p>Specifies the part after which listing should begin. Only parts with higher part numbers will be listed.</p>
298    pub fn get_part_number_marker(&self) -> &::std::option::Option<::std::string::String> {
299        self.inner.get_part_number_marker()
300    }
301    /// <p>Specifies the algorithm to use when encrypting the object (for example, AES256).</p><note>
302    /// <p>This functionality is not supported for directory buckets.</p>
303    /// </note>
304    pub fn sse_customer_algorithm(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
305        self.inner = self.inner.sse_customer_algorithm(input.into());
306        self
307    }
308    /// <p>Specifies the algorithm to use when encrypting the object (for example, AES256).</p><note>
309    /// <p>This functionality is not supported for directory buckets.</p>
310    /// </note>
311    pub fn set_sse_customer_algorithm(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
312        self.inner = self.inner.set_sse_customer_algorithm(input);
313        self
314    }
315    /// <p>Specifies the algorithm to use when encrypting the object (for example, AES256).</p><note>
316    /// <p>This functionality is not supported for directory buckets.</p>
317    /// </note>
318    pub fn get_sse_customer_algorithm(&self) -> &::std::option::Option<::std::string::String> {
319        self.inner.get_sse_customer_algorithm()
320    }
321    /// <p>Specifies the customer-provided encryption key for Amazon S3 to use in encrypting data. This value is used to store the object and then it is discarded; Amazon S3 does not store the encryption key. The key must be appropriate for use with the algorithm specified in the <code>x-amz-server-side-encryption-customer-algorithm</code> header.</p><note>
322    /// <p>This functionality is not supported for directory buckets.</p>
323    /// </note>
324    pub fn sse_customer_key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
325        self.inner = self.inner.sse_customer_key(input.into());
326        self
327    }
328    /// <p>Specifies the customer-provided encryption key for Amazon S3 to use in encrypting data. This value is used to store the object and then it is discarded; Amazon S3 does not store the encryption key. The key must be appropriate for use with the algorithm specified in the <code>x-amz-server-side-encryption-customer-algorithm</code> header.</p><note>
329    /// <p>This functionality is not supported for directory buckets.</p>
330    /// </note>
331    pub fn set_sse_customer_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
332        self.inner = self.inner.set_sse_customer_key(input);
333        self
334    }
335    /// <p>Specifies the customer-provided encryption key for Amazon S3 to use in encrypting data. This value is used to store the object and then it is discarded; Amazon S3 does not store the encryption key. The key must be appropriate for use with the algorithm specified in the <code>x-amz-server-side-encryption-customer-algorithm</code> header.</p><note>
336    /// <p>This functionality is not supported for directory buckets.</p>
337    /// </note>
338    pub fn get_sse_customer_key(&self) -> &::std::option::Option<::std::string::String> {
339        self.inner.get_sse_customer_key()
340    }
341    /// <p>Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321. Amazon S3 uses this header for a message integrity check to ensure that the encryption key was transmitted without error.</p><note>
342    /// <p>This functionality is not supported for directory buckets.</p>
343    /// </note>
344    pub fn sse_customer_key_md5(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
345        self.inner = self.inner.sse_customer_key_md5(input.into());
346        self
347    }
348    /// <p>Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321. Amazon S3 uses this header for a message integrity check to ensure that the encryption key was transmitted without error.</p><note>
349    /// <p>This functionality is not supported for directory buckets.</p>
350    /// </note>
351    pub fn set_sse_customer_key_md5(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
352        self.inner = self.inner.set_sse_customer_key_md5(input);
353        self
354    }
355    /// <p>Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321. Amazon S3 uses this header for a message integrity check to ensure that the encryption key was transmitted without error.</p><note>
356    /// <p>This functionality is not supported for directory buckets.</p>
357    /// </note>
358    pub fn get_sse_customer_key_md5(&self) -> &::std::option::Option<::std::string::String> {
359        self.inner.get_sse_customer_key_md5()
360    }
361    /// <p>Confirms that the requester knows that they will be charged for the request. Bucket owners need not specify this parameter in their requests. If either the source or destination S3 bucket has Requester Pays enabled, the requester will pay for corresponding charges to copy the object. For information about downloading objects from Requester Pays buckets, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html">Downloading Objects in Requester Pays Buckets</a> in the <i>Amazon S3 User Guide</i>.</p><note>
362    /// <p>This functionality is not supported for directory buckets.</p>
363    /// </note>
364    pub fn request_payer(mut self, input: crate::types::RequestPayer) -> Self {
365        self.inner = self.inner.request_payer(input);
366        self
367    }
368    /// <p>Confirms that the requester knows that they will be charged for the request. Bucket owners need not specify this parameter in their requests. If either the source or destination S3 bucket has Requester Pays enabled, the requester will pay for corresponding charges to copy the object. For information about downloading objects from Requester Pays buckets, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html">Downloading Objects in Requester Pays Buckets</a> in the <i>Amazon S3 User Guide</i>.</p><note>
369    /// <p>This functionality is not supported for directory buckets.</p>
370    /// </note>
371    pub fn set_request_payer(mut self, input: ::std::option::Option<crate::types::RequestPayer>) -> Self {
372        self.inner = self.inner.set_request_payer(input);
373        self
374    }
375    /// <p>Confirms that the requester knows that they will be charged for the request. Bucket owners need not specify this parameter in their requests. If either the source or destination S3 bucket has Requester Pays enabled, the requester will pay for corresponding charges to copy the object. For information about downloading objects from Requester Pays buckets, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html">Downloading Objects in Requester Pays Buckets</a> in the <i>Amazon S3 User Guide</i>.</p><note>
376    /// <p>This functionality is not supported for directory buckets.</p>
377    /// </note>
378    pub fn get_request_payer(&self) -> &::std::option::Option<crate::types::RequestPayer> {
379        self.inner.get_request_payer()
380    }
381    /// <p>The account ID of the expected bucket owner. If the account ID that you provide does not match the actual owner of the bucket, the request fails with the HTTP status code <code>403 Forbidden</code> (access denied).</p>
382    pub fn expected_bucket_owner(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
383        self.inner = self.inner.expected_bucket_owner(input.into());
384        self
385    }
386    /// <p>The account ID of the expected bucket owner. If the account ID that you provide does not match the actual owner of the bucket, the request fails with the HTTP status code <code>403 Forbidden</code> (access denied).</p>
387    pub fn set_expected_bucket_owner(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
388        self.inner = self.inner.set_expected_bucket_owner(input);
389        self
390    }
391    /// <p>The account ID of the expected bucket owner. If the account ID that you provide does not match the actual owner of the bucket, the request fails with the HTTP status code <code>403 Forbidden</code> (access denied).</p>
392    pub fn get_expected_bucket_owner(&self) -> &::std::option::Option<::std::string::String> {
393        self.inner.get_expected_bucket_owner()
394    }
395    ///
396    /// Appends an item to `ObjectAttributes`.
397    ///
398    /// To override the contents of this collection use [`set_object_attributes`](Self::set_object_attributes).
399    ///
400    /// <p>Specifies the fields at the root level that you want returned in the response. Fields that you do not specify are not returned.</p>
401    pub fn object_attributes(mut self, input: crate::types::ObjectAttributes) -> Self {
402        self.inner = self.inner.object_attributes(input);
403        self
404    }
405    /// <p>Specifies the fields at the root level that you want returned in the response. Fields that you do not specify are not returned.</p>
406    pub fn set_object_attributes(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::ObjectAttributes>>) -> Self {
407        self.inner = self.inner.set_object_attributes(input);
408        self
409    }
410    /// <p>Specifies the fields at the root level that you want returned in the response. Fields that you do not specify are not returned.</p>
411    pub fn get_object_attributes(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::ObjectAttributes>> {
412        self.inner.get_object_attributes()
413    }
414}