aws_sdk_s3/operation/upload_part_copy/
builders.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2pub use crate::operation::upload_part_copy::_upload_part_copy_output::UploadPartCopyOutputBuilder;
3
4pub use crate::operation::upload_part_copy::_upload_part_copy_input::UploadPartCopyInputBuilder;
5
6impl crate::operation::upload_part_copy::builders::UploadPartCopyInputBuilder {
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::upload_part_copy::UploadPartCopyOutput,
13        ::aws_smithy_runtime_api::client::result::SdkError<
14            crate::operation::upload_part_copy::UploadPartCopyError,
15            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
16        >,
17    > {
18        let mut fluent_builder = client.upload_part_copy();
19        fluent_builder.inner = self;
20        fluent_builder.send().await
21    }
22}
23/// Fluent builder constructing a request to `UploadPartCopy`.
24///
25/// <p>Uploads a part by copying data from an existing object as data source. To specify the data source, you add the request header <code>x-amz-copy-source</code> in your request. To specify a byte range, you add the request header <code>x-amz-copy-source-range</code> in your request.</p>
26/// <p>For information about maximum and minimum part sizes and other multipart upload specifications, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/qfacts.html">Multipart upload limits</a> in the <i>Amazon S3 User Guide</i>.</p><note>
27/// <p>Instead of copying data from an existing object as part data, you might use the <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPart.html">UploadPart</a> action to upload new data as a part of an object in your request.</p>
28/// </note>
29/// <p>You must initiate a multipart upload before you can upload any part. In response to your initiate request, Amazon S3 returns the upload ID, a unique identifier that you must include in your upload part request.</p>
30/// <p>For conceptual information about multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/uploadobjusingmpu.html">Uploading Objects Using Multipart Upload</a> in the <i>Amazon S3 User Guide</i>. For information about copying objects using a single atomic action vs. a multipart upload, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectOperations.html">Operations on Objects</a> in the <i>Amazon S3 User Guide</i>.</p><note>
31/// <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>
32/// </note>
33/// <dl>
34/// <dt>
35/// Authentication and authorization
36/// </dt>
37/// <dd>
38/// <p>All <code>UploadPartCopy</code> requests must be authenticated and signed by using IAM credentials (access key ID and secret access key for the IAM identities). All headers with the <code>x-amz-</code> prefix, including <code>x-amz-copy-source</code>, must be signed. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/RESTAuthentication.html">REST Authentication</a>.</p>
39/// <p><b>Directory buckets</b> - You must use IAM credentials to authenticate and authorize your access to the <code>UploadPartCopy</code> API operation, instead of using the temporary security credentials through the <code>CreateSession</code> API operation.</p>
40/// <p>Amazon Web Services CLI or SDKs handles authentication and authorization on your behalf.</p>
41/// </dd>
42/// <dt>
43/// Permissions
44/// </dt>
45/// <dd>
46/// <p>You must have <code>READ</code> access to the source object and <code>WRITE</code> access to the destination bucket.</p>
47/// <ul>
48/// <li>
49/// <p><b>General purpose bucket permissions</b> - You must have the permissions in a policy based on the bucket types of your source bucket and destination bucket in an <code>UploadPartCopy</code> operation.</p>
50/// <ul>
51/// <li>
52/// <p>If the source object is in a general purpose bucket, you must have the <b> <code>s3:GetObject</code> </b> permission to read the source object that is being copied.</p></li>
53/// <li>
54/// <p>If the destination bucket is a general purpose bucket, you must have the <b> <code>s3:PutObject</code> </b> permission to write the object copy to the destination bucket.</p></li>
55/// <li>
56/// <p>To perform a multipart upload with encryption using an Key Management Service key, the requester must have permission to the <code>kms:Decrypt</code> and <code>kms:GenerateDataKey</code> actions on the key. The requester must also have permissions for the <code>kms:GenerateDataKey</code> action for the <code>CreateMultipartUpload</code> API. Then, the requester needs permissions for the <code>kms:Decrypt</code> action on the <code>UploadPart</code> and <code>UploadPartCopy</code> APIs. These permissions are required because Amazon S3 must decrypt and read data from the encrypted file parts before it completes the multipart upload. For more information about KMS permissions, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/UsingKMSEncryption.html">Protecting data using server-side encryption with KMS</a> in the <i>Amazon S3 User Guide</i>. For information about the permissions required to use the multipart upload API, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuAndPermissions.html">Multipart upload and permissions</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/mpuoverview.html#mpuAndPermissions">Multipart upload API and permissions</a> in the <i>Amazon S3 User Guide</i>.</p></li>
57/// </ul></li>
58/// <li>
59/// <p><b>Directory bucket permissions</b> - You must have permissions in a bucket policy or an IAM identity-based policy based on the source and destination bucket types in an <code>UploadPartCopy</code> operation.</p>
60/// <ul>
61/// <li>
62/// <p>If the source object that you want to copy is in a directory bucket, you must have the <b> <code>s3express:CreateSession</code> </b> permission in the <code>Action</code> element of a policy to read the object. By default, the session is in the <code>ReadWrite</code> mode. If you want to restrict the access, you can explicitly set the <code>s3express:SessionMode</code> condition key to <code>ReadOnly</code> on the copy source bucket.</p></li>
63/// <li>
64/// <p>If the copy destination is a directory bucket, you must have the <b> <code>s3express:CreateSession</code> </b> permission in the <code>Action</code> element of a policy to write the object to the destination. The <code>s3express:SessionMode</code> condition key cannot be set to <code>ReadOnly</code> on the copy destination.</p></li>
65/// </ul>
66/// <p>For example policies, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-example-bucket-policies.html">Example bucket policies for S3 Express One Zone</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-security-iam-identity-policies.html">Amazon Web Services Identity and Access Management (IAM) identity-based policies for S3 Express One Zone</a> in the <i>Amazon S3 User Guide</i>.</p></li>
67/// </ul>
68/// </dd>
69/// <dt>
70/// Encryption
71/// </dt>
72/// <dd>
73/// <ul>
74/// <li>
75/// <p><b>General purpose buckets </b> - For information about using server-side encryption with customer-provided encryption keys with the <code>UploadPartCopy</code> operation, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html">CopyObject</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPart.html">UploadPart</a>.</p></li>
76/// <li>
77/// <p><b>Directory buckets </b> - For directory buckets, only server-side encryption with Amazon S3 managed keys (SSE-S3) (<code>AES256</code>) is supported.</p></li>
78/// </ul>
79/// </dd>
80/// <dt>
81/// Special errors
82/// </dt>
83/// <dd>
84/// <ul>
85/// <li>
86/// <p>Error Code: <code>NoSuchUpload</code></p>
87/// <ul>
88/// <li>
89/// <p>Description: The specified multipart upload does not exist. The upload ID might be invalid, or the multipart upload might have been aborted or completed.</p></li>
90/// <li>
91/// <p>HTTP Status Code: 404 Not Found</p></li>
92/// </ul></li>
93/// <li>
94/// <p>Error Code: <code>InvalidRequest</code></p>
95/// <ul>
96/// <li>
97/// <p>Description: The specified copy source is not supported as a byte-range copy source.</p></li>
98/// <li>
99/// <p>HTTP Status Code: 400 Bad Request</p></li>
100/// </ul></li>
101/// </ul>
102/// </dd>
103/// <dt>
104/// HTTP Host header syntax
105/// </dt>
106/// <dd>
107/// <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>
108/// </dd>
109/// </dl>
110/// <p>The following operations are related to <code>UploadPartCopy</code>:</p>
111/// <ul>
112/// <li>
113/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateMultipartUpload.html">CreateMultipartUpload</a></p></li>
114/// <li>
115/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPart.html">UploadPart</a></p></li>
116/// <li>
117/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CompleteMultipartUpload.html">CompleteMultipartUpload</a></p></li>
118/// <li>
119/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_AbortMultipartUpload.html">AbortMultipartUpload</a></p></li>
120/// <li>
121/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListParts.html">ListParts</a></p></li>
122/// <li>
123/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListMultipartUploads.html">ListMultipartUploads</a></p></li>
124/// </ul>
125#[derive(::std::clone::Clone, ::std::fmt::Debug)]
126pub struct UploadPartCopyFluentBuilder {
127    handle: ::std::sync::Arc<crate::client::Handle>,
128    inner: crate::operation::upload_part_copy::builders::UploadPartCopyInputBuilder,
129    config_override: ::std::option::Option<crate::config::Builder>,
130}
131impl
132    crate::client::customize::internal::CustomizableSend<
133        crate::operation::upload_part_copy::UploadPartCopyOutput,
134        crate::operation::upload_part_copy::UploadPartCopyError,
135    > for UploadPartCopyFluentBuilder
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::upload_part_copy::UploadPartCopyOutput,
143            crate::operation::upload_part_copy::UploadPartCopyError,
144        >,
145    > {
146        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
147    }
148}
149impl UploadPartCopyFluentBuilder {
150    /// Creates a new `UploadPartCopyFluentBuilder`.
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 UploadPartCopy as a reference.
159    pub fn as_input(&self) -> &crate::operation::upload_part_copy::builders::UploadPartCopyInputBuilder {
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::upload_part_copy::UploadPartCopyOutput,
174        ::aws_smithy_runtime_api::client::result::SdkError<
175            crate::operation::upload_part_copy::UploadPartCopyError,
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::upload_part_copy::UploadPartCopy::operation_runtime_plugins(
184            self.handle.runtime_plugins.clone(),
185            &self.handle.conf,
186            self.config_override,
187        );
188        crate::operation::upload_part_copy::UploadPartCopy::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::upload_part_copy::UploadPartCopyOutput,
196        crate::operation::upload_part_copy::UploadPartCopyError,
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 bucket name.</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 bucket name.</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 bucket name.</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>Specifies the source object for the copy operation. You specify the value in one of two formats, depending on whether you want to access the source object through an <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/access-points.html">access point</a>:</p>
240    /// <ul>
241    /// <li>
242    /// <p>For objects not accessed through an access point, specify the name of the source bucket and key of the source object, separated by a slash (/). For example, to copy the object <code>reports/january.pdf</code> from the bucket <code>awsexamplebucket</code>, use <code>awsexamplebucket/reports/january.pdf</code>. The value must be URL-encoded.</p></li>
243    /// <li>
244    /// <p>For objects accessed through access points, specify the Amazon Resource Name (ARN) of the object as accessed through the access point, in the format <code>arn:aws:s3:<region>
245    /// :
246    /// <account-id>
247    /// :accesspoint/
248    /// <access-point-name>
249    /// /object/
250    /// <key></key>
251    /// </access-point-name>
252    /// </account-id>
253    /// </region></code>. For example, to copy the object <code>reports/january.pdf</code> through access point <code>my-access-point</code> owned by account <code>123456789012</code> in Region <code>us-west-2</code>, use the URL encoding of <code>arn:aws:s3:us-west-2:123456789012:accesspoint/my-access-point/object/reports/january.pdf</code>. The value must be URL encoded.</p><note>
254    /// <ul>
255    /// <li>
256    /// <p>Amazon S3 supports copy operations using Access points only when the source and destination buckets are in the same Amazon Web Services Region.</p></li>
257    /// <li>
258    /// <p>Access points are not supported by directory buckets.</p></li>
259    /// </ul>
260    /// </note>
261    /// <p>Alternatively, for objects accessed through Amazon S3 on Outposts, specify the ARN of the object as accessed in the format <code>arn:aws:s3-outposts:<region>
262    /// :
263    /// <account-id>
264    /// :outpost/
265    /// <outpost-id>
266    /// /object/
267    /// <key></key>
268    /// </outpost-id>
269    /// </account-id>
270    /// </region></code>. For example, to copy the object <code>reports/january.pdf</code> through outpost <code>my-outpost</code> owned by account <code>123456789012</code> in Region <code>us-west-2</code>, use the URL encoding of <code>arn:aws:s3-outposts:us-west-2:123456789012:outpost/my-outpost/object/reports/january.pdf</code>. The value must be URL-encoded.</p></li>
271    /// </ul>
272    /// <p>If your bucket has versioning enabled, you could have multiple versions of the same object. By default, <code>x-amz-copy-source</code> identifies the current version of the source object to copy. To copy a specific version of the source object to copy, append <code>?versionId=<version-id></version-id></code> to the <code>x-amz-copy-source</code> request header (for example, <code>x-amz-copy-source: /awsexamplebucket/reports/january.pdf?versionId=QUpfdndhfd8438MNFDN93jdnJFkdmqnh893</code>).</p>
273    /// <p>If the current version is a delete marker and you don't specify a versionId in the <code>x-amz-copy-source</code> request header, Amazon S3 returns a <code>404 Not Found</code> error, because the object does not exist. If you specify versionId in the <code>x-amz-copy-source</code> and the versionId is a delete marker, Amazon S3 returns an HTTP <code>400 Bad Request</code> error, because you are not allowed to specify a delete marker as a version for the <code>x-amz-copy-source</code>.</p><note>
274    /// <p><b>Directory buckets</b> - S3 Versioning isn't enabled and supported for directory buckets.</p>
275    /// </note>
276    pub fn copy_source(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
277        self.inner = self.inner.copy_source(input.into());
278        self
279    }
280    /// <p>Specifies the source object for the copy operation. You specify the value in one of two formats, depending on whether you want to access the source object through an <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/access-points.html">access point</a>:</p>
281    /// <ul>
282    /// <li>
283    /// <p>For objects not accessed through an access point, specify the name of the source bucket and key of the source object, separated by a slash (/). For example, to copy the object <code>reports/january.pdf</code> from the bucket <code>awsexamplebucket</code>, use <code>awsexamplebucket/reports/january.pdf</code>. The value must be URL-encoded.</p></li>
284    /// <li>
285    /// <p>For objects accessed through access points, specify the Amazon Resource Name (ARN) of the object as accessed through the access point, in the format <code>arn:aws:s3:<region>
286    /// :
287    /// <account-id>
288    /// :accesspoint/
289    /// <access-point-name>
290    /// /object/
291    /// <key></key>
292    /// </access-point-name>
293    /// </account-id>
294    /// </region></code>. For example, to copy the object <code>reports/january.pdf</code> through access point <code>my-access-point</code> owned by account <code>123456789012</code> in Region <code>us-west-2</code>, use the URL encoding of <code>arn:aws:s3:us-west-2:123456789012:accesspoint/my-access-point/object/reports/january.pdf</code>. The value must be URL encoded.</p><note>
295    /// <ul>
296    /// <li>
297    /// <p>Amazon S3 supports copy operations using Access points only when the source and destination buckets are in the same Amazon Web Services Region.</p></li>
298    /// <li>
299    /// <p>Access points are not supported by directory buckets.</p></li>
300    /// </ul>
301    /// </note>
302    /// <p>Alternatively, for objects accessed through Amazon S3 on Outposts, specify the ARN of the object as accessed in the format <code>arn:aws:s3-outposts:<region>
303    /// :
304    /// <account-id>
305    /// :outpost/
306    /// <outpost-id>
307    /// /object/
308    /// <key></key>
309    /// </outpost-id>
310    /// </account-id>
311    /// </region></code>. For example, to copy the object <code>reports/january.pdf</code> through outpost <code>my-outpost</code> owned by account <code>123456789012</code> in Region <code>us-west-2</code>, use the URL encoding of <code>arn:aws:s3-outposts:us-west-2:123456789012:outpost/my-outpost/object/reports/january.pdf</code>. The value must be URL-encoded.</p></li>
312    /// </ul>
313    /// <p>If your bucket has versioning enabled, you could have multiple versions of the same object. By default, <code>x-amz-copy-source</code> identifies the current version of the source object to copy. To copy a specific version of the source object to copy, append <code>?versionId=<version-id></version-id></code> to the <code>x-amz-copy-source</code> request header (for example, <code>x-amz-copy-source: /awsexamplebucket/reports/january.pdf?versionId=QUpfdndhfd8438MNFDN93jdnJFkdmqnh893</code>).</p>
314    /// <p>If the current version is a delete marker and you don't specify a versionId in the <code>x-amz-copy-source</code> request header, Amazon S3 returns a <code>404 Not Found</code> error, because the object does not exist. If you specify versionId in the <code>x-amz-copy-source</code> and the versionId is a delete marker, Amazon S3 returns an HTTP <code>400 Bad Request</code> error, because you are not allowed to specify a delete marker as a version for the <code>x-amz-copy-source</code>.</p><note>
315    /// <p><b>Directory buckets</b> - S3 Versioning isn't enabled and supported for directory buckets.</p>
316    /// </note>
317    pub fn set_copy_source(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
318        self.inner = self.inner.set_copy_source(input);
319        self
320    }
321    /// <p>Specifies the source object for the copy operation. You specify the value in one of two formats, depending on whether you want to access the source object through an <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/access-points.html">access point</a>:</p>
322    /// <ul>
323    /// <li>
324    /// <p>For objects not accessed through an access point, specify the name of the source bucket and key of the source object, separated by a slash (/). For example, to copy the object <code>reports/january.pdf</code> from the bucket <code>awsexamplebucket</code>, use <code>awsexamplebucket/reports/january.pdf</code>. The value must be URL-encoded.</p></li>
325    /// <li>
326    /// <p>For objects accessed through access points, specify the Amazon Resource Name (ARN) of the object as accessed through the access point, in the format <code>arn:aws:s3:<region>
327    /// :
328    /// <account-id>
329    /// :accesspoint/
330    /// <access-point-name>
331    /// /object/
332    /// <key></key>
333    /// </access-point-name>
334    /// </account-id>
335    /// </region></code>. For example, to copy the object <code>reports/january.pdf</code> through access point <code>my-access-point</code> owned by account <code>123456789012</code> in Region <code>us-west-2</code>, use the URL encoding of <code>arn:aws:s3:us-west-2:123456789012:accesspoint/my-access-point/object/reports/january.pdf</code>. The value must be URL encoded.</p><note>
336    /// <ul>
337    /// <li>
338    /// <p>Amazon S3 supports copy operations using Access points only when the source and destination buckets are in the same Amazon Web Services Region.</p></li>
339    /// <li>
340    /// <p>Access points are not supported by directory buckets.</p></li>
341    /// </ul>
342    /// </note>
343    /// <p>Alternatively, for objects accessed through Amazon S3 on Outposts, specify the ARN of the object as accessed in the format <code>arn:aws:s3-outposts:<region>
344    /// :
345    /// <account-id>
346    /// :outpost/
347    /// <outpost-id>
348    /// /object/
349    /// <key></key>
350    /// </outpost-id>
351    /// </account-id>
352    /// </region></code>. For example, to copy the object <code>reports/january.pdf</code> through outpost <code>my-outpost</code> owned by account <code>123456789012</code> in Region <code>us-west-2</code>, use the URL encoding of <code>arn:aws:s3-outposts:us-west-2:123456789012:outpost/my-outpost/object/reports/january.pdf</code>. The value must be URL-encoded.</p></li>
353    /// </ul>
354    /// <p>If your bucket has versioning enabled, you could have multiple versions of the same object. By default, <code>x-amz-copy-source</code> identifies the current version of the source object to copy. To copy a specific version of the source object to copy, append <code>?versionId=<version-id></version-id></code> to the <code>x-amz-copy-source</code> request header (for example, <code>x-amz-copy-source: /awsexamplebucket/reports/january.pdf?versionId=QUpfdndhfd8438MNFDN93jdnJFkdmqnh893</code>).</p>
355    /// <p>If the current version is a delete marker and you don't specify a versionId in the <code>x-amz-copy-source</code> request header, Amazon S3 returns a <code>404 Not Found</code> error, because the object does not exist. If you specify versionId in the <code>x-amz-copy-source</code> and the versionId is a delete marker, Amazon S3 returns an HTTP <code>400 Bad Request</code> error, because you are not allowed to specify a delete marker as a version for the <code>x-amz-copy-source</code>.</p><note>
356    /// <p><b>Directory buckets</b> - S3 Versioning isn't enabled and supported for directory buckets.</p>
357    /// </note>
358    pub fn get_copy_source(&self) -> &::std::option::Option<::std::string::String> {
359        self.inner.get_copy_source()
360    }
361    /// <p>Copies the object if its entity tag (ETag) matches the specified tag.</p>
362    /// <p>If both of the <code>x-amz-copy-source-if-match</code> and <code>x-amz-copy-source-if-unmodified-since</code> headers are present in the request as follows:</p>
363    /// <p><code>x-amz-copy-source-if-match</code> condition evaluates to <code>true</code>, and;</p>
364    /// <p><code>x-amz-copy-source-if-unmodified-since</code> condition evaluates to <code>false</code>;</p>
365    /// <p>Amazon S3 returns <code>200 OK</code> and copies the data.</p>
366    pub fn copy_source_if_match(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
367        self.inner = self.inner.copy_source_if_match(input.into());
368        self
369    }
370    /// <p>Copies the object if its entity tag (ETag) matches the specified tag.</p>
371    /// <p>If both of the <code>x-amz-copy-source-if-match</code> and <code>x-amz-copy-source-if-unmodified-since</code> headers are present in the request as follows:</p>
372    /// <p><code>x-amz-copy-source-if-match</code> condition evaluates to <code>true</code>, and;</p>
373    /// <p><code>x-amz-copy-source-if-unmodified-since</code> condition evaluates to <code>false</code>;</p>
374    /// <p>Amazon S3 returns <code>200 OK</code> and copies the data.</p>
375    pub fn set_copy_source_if_match(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
376        self.inner = self.inner.set_copy_source_if_match(input);
377        self
378    }
379    /// <p>Copies the object if its entity tag (ETag) matches the specified tag.</p>
380    /// <p>If both of the <code>x-amz-copy-source-if-match</code> and <code>x-amz-copy-source-if-unmodified-since</code> headers are present in the request as follows:</p>
381    /// <p><code>x-amz-copy-source-if-match</code> condition evaluates to <code>true</code>, and;</p>
382    /// <p><code>x-amz-copy-source-if-unmodified-since</code> condition evaluates to <code>false</code>;</p>
383    /// <p>Amazon S3 returns <code>200 OK</code> and copies the data.</p>
384    pub fn get_copy_source_if_match(&self) -> &::std::option::Option<::std::string::String> {
385        self.inner.get_copy_source_if_match()
386    }
387    /// <p>Copies the object if it has been modified since the specified time.</p>
388    /// <p>If both of the <code>x-amz-copy-source-if-none-match</code> and <code>x-amz-copy-source-if-modified-since</code> headers are present in the request as follows:</p>
389    /// <p><code>x-amz-copy-source-if-none-match</code> condition evaluates to <code>false</code>, and;</p>
390    /// <p><code>x-amz-copy-source-if-modified-since</code> condition evaluates to <code>true</code>;</p>
391    /// <p>Amazon S3 returns <code>412 Precondition Failed</code> response code.</p>
392    pub fn copy_source_if_modified_since(mut self, input: ::aws_smithy_types::DateTime) -> Self {
393        self.inner = self.inner.copy_source_if_modified_since(input);
394        self
395    }
396    /// <p>Copies the object if it has been modified since the specified time.</p>
397    /// <p>If both of the <code>x-amz-copy-source-if-none-match</code> and <code>x-amz-copy-source-if-modified-since</code> headers are present in the request as follows:</p>
398    /// <p><code>x-amz-copy-source-if-none-match</code> condition evaluates to <code>false</code>, and;</p>
399    /// <p><code>x-amz-copy-source-if-modified-since</code> condition evaluates to <code>true</code>;</p>
400    /// <p>Amazon S3 returns <code>412 Precondition Failed</code> response code.</p>
401    pub fn set_copy_source_if_modified_since(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
402        self.inner = self.inner.set_copy_source_if_modified_since(input);
403        self
404    }
405    /// <p>Copies the object if it has been modified since the specified time.</p>
406    /// <p>If both of the <code>x-amz-copy-source-if-none-match</code> and <code>x-amz-copy-source-if-modified-since</code> headers are present in the request as follows:</p>
407    /// <p><code>x-amz-copy-source-if-none-match</code> condition evaluates to <code>false</code>, and;</p>
408    /// <p><code>x-amz-copy-source-if-modified-since</code> condition evaluates to <code>true</code>;</p>
409    /// <p>Amazon S3 returns <code>412 Precondition Failed</code> response code.</p>
410    pub fn get_copy_source_if_modified_since(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
411        self.inner.get_copy_source_if_modified_since()
412    }
413    /// <p>Copies the object if its entity tag (ETag) is different than the specified ETag.</p>
414    /// <p>If both of the <code>x-amz-copy-source-if-none-match</code> and <code>x-amz-copy-source-if-modified-since</code> headers are present in the request as follows:</p>
415    /// <p><code>x-amz-copy-source-if-none-match</code> condition evaluates to <code>false</code>, and;</p>
416    /// <p><code>x-amz-copy-source-if-modified-since</code> condition evaluates to <code>true</code>;</p>
417    /// <p>Amazon S3 returns <code>412 Precondition Failed</code> response code.</p>
418    pub fn copy_source_if_none_match(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
419        self.inner = self.inner.copy_source_if_none_match(input.into());
420        self
421    }
422    /// <p>Copies the object if its entity tag (ETag) is different than the specified ETag.</p>
423    /// <p>If both of the <code>x-amz-copy-source-if-none-match</code> and <code>x-amz-copy-source-if-modified-since</code> headers are present in the request as follows:</p>
424    /// <p><code>x-amz-copy-source-if-none-match</code> condition evaluates to <code>false</code>, and;</p>
425    /// <p><code>x-amz-copy-source-if-modified-since</code> condition evaluates to <code>true</code>;</p>
426    /// <p>Amazon S3 returns <code>412 Precondition Failed</code> response code.</p>
427    pub fn set_copy_source_if_none_match(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
428        self.inner = self.inner.set_copy_source_if_none_match(input);
429        self
430    }
431    /// <p>Copies the object if its entity tag (ETag) is different than the specified ETag.</p>
432    /// <p>If both of the <code>x-amz-copy-source-if-none-match</code> and <code>x-amz-copy-source-if-modified-since</code> headers are present in the request as follows:</p>
433    /// <p><code>x-amz-copy-source-if-none-match</code> condition evaluates to <code>false</code>, and;</p>
434    /// <p><code>x-amz-copy-source-if-modified-since</code> condition evaluates to <code>true</code>;</p>
435    /// <p>Amazon S3 returns <code>412 Precondition Failed</code> response code.</p>
436    pub fn get_copy_source_if_none_match(&self) -> &::std::option::Option<::std::string::String> {
437        self.inner.get_copy_source_if_none_match()
438    }
439    /// <p>Copies the object if it hasn't been modified since the specified time.</p>
440    /// <p>If both of the <code>x-amz-copy-source-if-match</code> and <code>x-amz-copy-source-if-unmodified-since</code> headers are present in the request as follows:</p>
441    /// <p><code>x-amz-copy-source-if-match</code> condition evaluates to <code>true</code>, and;</p>
442    /// <p><code>x-amz-copy-source-if-unmodified-since</code> condition evaluates to <code>false</code>;</p>
443    /// <p>Amazon S3 returns <code>200 OK</code> and copies the data.</p>
444    pub fn copy_source_if_unmodified_since(mut self, input: ::aws_smithy_types::DateTime) -> Self {
445        self.inner = self.inner.copy_source_if_unmodified_since(input);
446        self
447    }
448    /// <p>Copies the object if it hasn't been modified since the specified time.</p>
449    /// <p>If both of the <code>x-amz-copy-source-if-match</code> and <code>x-amz-copy-source-if-unmodified-since</code> headers are present in the request as follows:</p>
450    /// <p><code>x-amz-copy-source-if-match</code> condition evaluates to <code>true</code>, and;</p>
451    /// <p><code>x-amz-copy-source-if-unmodified-since</code> condition evaluates to <code>false</code>;</p>
452    /// <p>Amazon S3 returns <code>200 OK</code> and copies the data.</p>
453    pub fn set_copy_source_if_unmodified_since(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
454        self.inner = self.inner.set_copy_source_if_unmodified_since(input);
455        self
456    }
457    /// <p>Copies the object if it hasn't been modified since the specified time.</p>
458    /// <p>If both of the <code>x-amz-copy-source-if-match</code> and <code>x-amz-copy-source-if-unmodified-since</code> headers are present in the request as follows:</p>
459    /// <p><code>x-amz-copy-source-if-match</code> condition evaluates to <code>true</code>, and;</p>
460    /// <p><code>x-amz-copy-source-if-unmodified-since</code> condition evaluates to <code>false</code>;</p>
461    /// <p>Amazon S3 returns <code>200 OK</code> and copies the data.</p>
462    pub fn get_copy_source_if_unmodified_since(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
463        self.inner.get_copy_source_if_unmodified_since()
464    }
465    /// <p>The range of bytes to copy from the source object. The range value must use the form bytes=first-last, where the first and last are the zero-based byte offsets to copy. For example, bytes=0-9 indicates that you want to copy the first 10 bytes of the source. You can copy a range only if the source object is greater than 5 MB.</p>
466    pub fn copy_source_range(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
467        self.inner = self.inner.copy_source_range(input.into());
468        self
469    }
470    /// <p>The range of bytes to copy from the source object. The range value must use the form bytes=first-last, where the first and last are the zero-based byte offsets to copy. For example, bytes=0-9 indicates that you want to copy the first 10 bytes of the source. You can copy a range only if the source object is greater than 5 MB.</p>
471    pub fn set_copy_source_range(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
472        self.inner = self.inner.set_copy_source_range(input);
473        self
474    }
475    /// <p>The range of bytes to copy from the source object. The range value must use the form bytes=first-last, where the first and last are the zero-based byte offsets to copy. For example, bytes=0-9 indicates that you want to copy the first 10 bytes of the source. You can copy a range only if the source object is greater than 5 MB.</p>
476    pub fn get_copy_source_range(&self) -> &::std::option::Option<::std::string::String> {
477        self.inner.get_copy_source_range()
478    }
479    /// <p>Object key for which the multipart upload was initiated.</p>
480    pub fn key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
481        self.inner = self.inner.key(input.into());
482        self
483    }
484    /// <p>Object key for which the multipart upload was initiated.</p>
485    pub fn set_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
486        self.inner = self.inner.set_key(input);
487        self
488    }
489    /// <p>Object key for which the multipart upload was initiated.</p>
490    pub fn get_key(&self) -> &::std::option::Option<::std::string::String> {
491        self.inner.get_key()
492    }
493    /// <p>Part number of part being copied. This is a positive integer between 1 and 10,000.</p>
494    pub fn part_number(mut self, input: i32) -> Self {
495        self.inner = self.inner.part_number(input);
496        self
497    }
498    /// <p>Part number of part being copied. This is a positive integer between 1 and 10,000.</p>
499    pub fn set_part_number(mut self, input: ::std::option::Option<i32>) -> Self {
500        self.inner = self.inner.set_part_number(input);
501        self
502    }
503    /// <p>Part number of part being copied. This is a positive integer between 1 and 10,000.</p>
504    pub fn get_part_number(&self) -> &::std::option::Option<i32> {
505        self.inner.get_part_number()
506    }
507    /// <p>Upload ID identifying the multipart upload whose part is being copied.</p>
508    pub fn upload_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
509        self.inner = self.inner.upload_id(input.into());
510        self
511    }
512    /// <p>Upload ID identifying the multipart upload whose part is being copied.</p>
513    pub fn set_upload_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
514        self.inner = self.inner.set_upload_id(input);
515        self
516    }
517    /// <p>Upload ID identifying the multipart upload whose part is being copied.</p>
518    pub fn get_upload_id(&self) -> &::std::option::Option<::std::string::String> {
519        self.inner.get_upload_id()
520    }
521    /// <p>Specifies the algorithm to use when encrypting the object (for example, AES256).</p><note>
522    /// <p>This functionality is not supported when the destination bucket is a directory bucket.</p>
523    /// </note>
524    pub fn sse_customer_algorithm(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
525        self.inner = self.inner.sse_customer_algorithm(input.into());
526        self
527    }
528    /// <p>Specifies the algorithm to use when encrypting the object (for example, AES256).</p><note>
529    /// <p>This functionality is not supported when the destination bucket is a directory bucket.</p>
530    /// </note>
531    pub fn set_sse_customer_algorithm(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
532        self.inner = self.inner.set_sse_customer_algorithm(input);
533        self
534    }
535    /// <p>Specifies the algorithm to use when encrypting the object (for example, AES256).</p><note>
536    /// <p>This functionality is not supported when the destination bucket is a directory bucket.</p>
537    /// </note>
538    pub fn get_sse_customer_algorithm(&self) -> &::std::option::Option<::std::string::String> {
539        self.inner.get_sse_customer_algorithm()
540    }
541    /// <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. This must be the same encryption key specified in the initiate multipart upload request.</p><note>
542    /// <p>This functionality is not supported when the destination bucket is a directory bucket.</p>
543    /// </note>
544    pub fn sse_customer_key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
545        self.inner = self.inner.sse_customer_key(input.into());
546        self
547    }
548    /// <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. This must be the same encryption key specified in the initiate multipart upload request.</p><note>
549    /// <p>This functionality is not supported when the destination bucket is a directory bucket.</p>
550    /// </note>
551    pub fn set_sse_customer_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
552        self.inner = self.inner.set_sse_customer_key(input);
553        self
554    }
555    /// <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. This must be the same encryption key specified in the initiate multipart upload request.</p><note>
556    /// <p>This functionality is not supported when the destination bucket is a directory bucket.</p>
557    /// </note>
558    pub fn get_sse_customer_key(&self) -> &::std::option::Option<::std::string::String> {
559        self.inner.get_sse_customer_key()
560    }
561    /// <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>
562    /// <p>This functionality is not supported when the destination bucket is a directory bucket.</p>
563    /// </note>
564    pub fn sse_customer_key_md5(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
565        self.inner = self.inner.sse_customer_key_md5(input.into());
566        self
567    }
568    /// <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>
569    /// <p>This functionality is not supported when the destination bucket is a directory bucket.</p>
570    /// </note>
571    pub fn set_sse_customer_key_md5(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
572        self.inner = self.inner.set_sse_customer_key_md5(input);
573        self
574    }
575    /// <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>
576    /// <p>This functionality is not supported when the destination bucket is a directory bucket.</p>
577    /// </note>
578    pub fn get_sse_customer_key_md5(&self) -> &::std::option::Option<::std::string::String> {
579        self.inner.get_sse_customer_key_md5()
580    }
581    /// <p>Specifies the algorithm to use when decrypting the source object (for example, <code>AES256</code>).</p><note>
582    /// <p>This functionality is not supported when the source object is in a directory bucket.</p>
583    /// </note>
584    pub fn copy_source_sse_customer_algorithm(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
585        self.inner = self.inner.copy_source_sse_customer_algorithm(input.into());
586        self
587    }
588    /// <p>Specifies the algorithm to use when decrypting the source object (for example, <code>AES256</code>).</p><note>
589    /// <p>This functionality is not supported when the source object is in a directory bucket.</p>
590    /// </note>
591    pub fn set_copy_source_sse_customer_algorithm(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
592        self.inner = self.inner.set_copy_source_sse_customer_algorithm(input);
593        self
594    }
595    /// <p>Specifies the algorithm to use when decrypting the source object (for example, <code>AES256</code>).</p><note>
596    /// <p>This functionality is not supported when the source object is in a directory bucket.</p>
597    /// </note>
598    pub fn get_copy_source_sse_customer_algorithm(&self) -> &::std::option::Option<::std::string::String> {
599        self.inner.get_copy_source_sse_customer_algorithm()
600    }
601    /// <p>Specifies the customer-provided encryption key for Amazon S3 to use to decrypt the source object. The encryption key provided in this header must be one that was used when the source object was created.</p><note>
602    /// <p>This functionality is not supported when the source object is in a directory bucket.</p>
603    /// </note>
604    pub fn copy_source_sse_customer_key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
605        self.inner = self.inner.copy_source_sse_customer_key(input.into());
606        self
607    }
608    /// <p>Specifies the customer-provided encryption key for Amazon S3 to use to decrypt the source object. The encryption key provided in this header must be one that was used when the source object was created.</p><note>
609    /// <p>This functionality is not supported when the source object is in a directory bucket.</p>
610    /// </note>
611    pub fn set_copy_source_sse_customer_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
612        self.inner = self.inner.set_copy_source_sse_customer_key(input);
613        self
614    }
615    /// <p>Specifies the customer-provided encryption key for Amazon S3 to use to decrypt the source object. The encryption key provided in this header must be one that was used when the source object was created.</p><note>
616    /// <p>This functionality is not supported when the source object is in a directory bucket.</p>
617    /// </note>
618    pub fn get_copy_source_sse_customer_key(&self) -> &::std::option::Option<::std::string::String> {
619        self.inner.get_copy_source_sse_customer_key()
620    }
621    /// <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>
622    /// <p>This functionality is not supported when the source object is in a directory bucket.</p>
623    /// </note>
624    pub fn copy_source_sse_customer_key_md5(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
625        self.inner = self.inner.copy_source_sse_customer_key_md5(input.into());
626        self
627    }
628    /// <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>
629    /// <p>This functionality is not supported when the source object is in a directory bucket.</p>
630    /// </note>
631    pub fn set_copy_source_sse_customer_key_md5(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
632        self.inner = self.inner.set_copy_source_sse_customer_key_md5(input);
633        self
634    }
635    /// <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>
636    /// <p>This functionality is not supported when the source object is in a directory bucket.</p>
637    /// </note>
638    pub fn get_copy_source_sse_customer_key_md5(&self) -> &::std::option::Option<::std::string::String> {
639        self.inner.get_copy_source_sse_customer_key_md5()
640    }
641    /// <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>
642    /// <p>This functionality is not supported for directory buckets.</p>
643    /// </note>
644    pub fn request_payer(mut self, input: crate::types::RequestPayer) -> Self {
645        self.inner = self.inner.request_payer(input);
646        self
647    }
648    /// <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>
649    /// <p>This functionality is not supported for directory buckets.</p>
650    /// </note>
651    pub fn set_request_payer(mut self, input: ::std::option::Option<crate::types::RequestPayer>) -> Self {
652        self.inner = self.inner.set_request_payer(input);
653        self
654    }
655    /// <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>
656    /// <p>This functionality is not supported for directory buckets.</p>
657    /// </note>
658    pub fn get_request_payer(&self) -> &::std::option::Option<crate::types::RequestPayer> {
659        self.inner.get_request_payer()
660    }
661    /// <p>The account ID of the expected destination bucket owner. If the account ID that you provide does not match the actual owner of the destination bucket, the request fails with the HTTP status code <code>403 Forbidden</code> (access denied).</p>
662    pub fn expected_bucket_owner(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
663        self.inner = self.inner.expected_bucket_owner(input.into());
664        self
665    }
666    /// <p>The account ID of the expected destination bucket owner. If the account ID that you provide does not match the actual owner of the destination bucket, the request fails with the HTTP status code <code>403 Forbidden</code> (access denied).</p>
667    pub fn set_expected_bucket_owner(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
668        self.inner = self.inner.set_expected_bucket_owner(input);
669        self
670    }
671    /// <p>The account ID of the expected destination bucket owner. If the account ID that you provide does not match the actual owner of the destination bucket, the request fails with the HTTP status code <code>403 Forbidden</code> (access denied).</p>
672    pub fn get_expected_bucket_owner(&self) -> &::std::option::Option<::std::string::String> {
673        self.inner.get_expected_bucket_owner()
674    }
675    /// <p>The account ID of the expected source bucket owner. If the account ID that you provide does not match the actual owner of the source bucket, the request fails with the HTTP status code <code>403 Forbidden</code> (access denied).</p>
676    pub fn expected_source_bucket_owner(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
677        self.inner = self.inner.expected_source_bucket_owner(input.into());
678        self
679    }
680    /// <p>The account ID of the expected source bucket owner. If the account ID that you provide does not match the actual owner of the source bucket, the request fails with the HTTP status code <code>403 Forbidden</code> (access denied).</p>
681    pub fn set_expected_source_bucket_owner(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
682        self.inner = self.inner.set_expected_source_bucket_owner(input);
683        self
684    }
685    /// <p>The account ID of the expected source bucket owner. If the account ID that you provide does not match the actual owner of the source bucket, the request fails with the HTTP status code <code>403 Forbidden</code> (access denied).</p>
686    pub fn get_expected_source_bucket_owner(&self) -> &::std::option::Option<::std::string::String> {
687        self.inner.get_expected_source_bucket_owner()
688    }
689}