aws_sdk_s3/operation/upload_part/
_upload_part_input.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2#[allow(missing_docs)] // documentation missing in model
3#[non_exhaustive]
4pub struct UploadPartInput {
5    /// <p>Object data.</p>
6    pub body: ::aws_smithy_types::byte_stream::ByteStream,
7    /// <p>The name of the bucket to which the multipart upload was initiated.</p>
8    /// <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>zone-id</i>.<i>region-code</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Zone (Availability Zone or Local Zone). Bucket names must follow the format <code> <i>bucket-base-name</i>--<i>zone-id</i>--x-s3</code> (for example, <code> <i>amzn-s3-demo-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>
9    /// <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>
10    /// <p>Access points and Object Lambda access points are not supported by directory buckets.</p>
11    /// </note>
12    /// <p><b>S3 on Outposts</b> - When you use this action with 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, the destination bucket must be the Outposts access point ARN or the access point alias. For more information about S3 on Outposts, 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>
13    pub bucket: ::std::option::Option<::std::string::String>,
14    /// <p>Size of the body in bytes. This parameter is useful when the size of the body cannot be determined automatically.</p>
15    pub content_length: ::std::option::Option<i64>,
16    /// <p>The Base64 encoded 128-bit MD5 digest of the part data. This parameter is auto-populated when using the command from the CLI. This parameter is required if object lock parameters are specified.</p><note>
17    /// <p>This functionality is not supported for directory buckets.</p>
18    /// </note>
19    pub content_md5: ::std::option::Option<::std::string::String>,
20    /// <p>Indicates the algorithm used to create the checksum for the object when you use the SDK. This header will not provide any additional functionality if you don't use the SDK. When you send this header, there must be a corresponding <code>x-amz-checksum</code> or <code>x-amz-trailer</code> header sent. Otherwise, Amazon S3 fails the request with the HTTP status code <code>400 Bad Request</code>. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
21    /// <p>If you provide an individual checksum, Amazon S3 ignores any provided <code>ChecksumAlgorithm</code> parameter.</p>
22    /// <p>This checksum algorithm must be the same for all parts and it match the checksum value supplied in the <code>CreateMultipartUpload</code> request.</p>
23    pub checksum_algorithm: ::std::option::Option<crate::types::ChecksumAlgorithm>,
24    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
25    pub checksum_crc32: ::std::option::Option<::std::string::String>,
26    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32C</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
27    pub checksum_crc32_c: ::std::option::Option<::std::string::String>,
28    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>CRC64NVME</code> checksum of the part. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
29    pub checksum_crc64_nvme: ::std::option::Option<::std::string::String>,
30    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 160-bit <code>SHA1</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
31    pub checksum_sha1: ::std::option::Option<::std::string::String>,
32    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 256-bit <code>SHA256</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
33    pub checksum_sha256: ::std::option::Option<::std::string::String>,
34    /// <p>Object key for which the multipart upload was initiated.</p>
35    pub key: ::std::option::Option<::std::string::String>,
36    /// <p>Part number of part being uploaded. This is a positive integer between 1 and 10,000.</p>
37    pub part_number: ::std::option::Option<i32>,
38    /// <p>Upload ID identifying the multipart upload whose part is being uploaded.</p>
39    pub upload_id: ::std::option::Option<::std::string::String>,
40    /// <p>Specifies the algorithm to use when encrypting the object (for example, AES256).</p><note>
41    /// <p>This functionality is not supported for directory buckets.</p>
42    /// </note>
43    pub sse_customer_algorithm: ::std::option::Option<::std::string::String>,
44    /// <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 header</code>. This must be the same encryption key specified in the initiate multipart upload request.</p><note>
45    /// <p>This functionality is not supported for directory buckets.</p>
46    /// </note>
47    pub sse_customer_key: ::std::option::Option<::std::string::String>,
48    /// <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>
49    /// <p>This functionality is not supported for directory buckets.</p>
50    /// </note>
51    pub sse_customer_key_md5: ::std::option::Option<::std::string::String>,
52    /// <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>
53    /// <p>This functionality is not supported for directory buckets.</p>
54    /// </note>
55    pub request_payer: ::std::option::Option<crate::types::RequestPayer>,
56    /// <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>
57    pub expected_bucket_owner: ::std::option::Option<::std::string::String>,
58}
59impl UploadPartInput {
60    /// <p>Object data.</p>
61    pub fn body(&self) -> &::aws_smithy_types::byte_stream::ByteStream {
62        &self.body
63    }
64    /// <p>The name of the bucket to which the multipart upload was initiated.</p>
65    /// <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>zone-id</i>.<i>region-code</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Zone (Availability Zone or Local Zone). Bucket names must follow the format <code> <i>bucket-base-name</i>--<i>zone-id</i>--x-s3</code> (for example, <code> <i>amzn-s3-demo-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>
66    /// <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>
67    /// <p>Access points and Object Lambda access points are not supported by directory buckets.</p>
68    /// </note>
69    /// <p><b>S3 on Outposts</b> - When you use this action with 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, the destination bucket must be the Outposts access point ARN or the access point alias. For more information about S3 on Outposts, 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>
70    pub fn bucket(&self) -> ::std::option::Option<&str> {
71        self.bucket.as_deref()
72    }
73    /// <p>Size of the body in bytes. This parameter is useful when the size of the body cannot be determined automatically.</p>
74    pub fn content_length(&self) -> ::std::option::Option<i64> {
75        self.content_length
76    }
77    /// <p>The Base64 encoded 128-bit MD5 digest of the part data. This parameter is auto-populated when using the command from the CLI. This parameter is required if object lock parameters are specified.</p><note>
78    /// <p>This functionality is not supported for directory buckets.</p>
79    /// </note>
80    pub fn content_md5(&self) -> ::std::option::Option<&str> {
81        self.content_md5.as_deref()
82    }
83    /// <p>Indicates the algorithm used to create the checksum for the object when you use the SDK. This header will not provide any additional functionality if you don't use the SDK. When you send this header, there must be a corresponding <code>x-amz-checksum</code> or <code>x-amz-trailer</code> header sent. Otherwise, Amazon S3 fails the request with the HTTP status code <code>400 Bad Request</code>. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
84    /// <p>If you provide an individual checksum, Amazon S3 ignores any provided <code>ChecksumAlgorithm</code> parameter.</p>
85    /// <p>This checksum algorithm must be the same for all parts and it match the checksum value supplied in the <code>CreateMultipartUpload</code> request.</p>
86    pub fn checksum_algorithm(&self) -> ::std::option::Option<&crate::types::ChecksumAlgorithm> {
87        self.checksum_algorithm.as_ref()
88    }
89    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
90    pub fn checksum_crc32(&self) -> ::std::option::Option<&str> {
91        self.checksum_crc32.as_deref()
92    }
93    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32C</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
94    pub fn checksum_crc32_c(&self) -> ::std::option::Option<&str> {
95        self.checksum_crc32_c.as_deref()
96    }
97    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>CRC64NVME</code> checksum of the part. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
98    pub fn checksum_crc64_nvme(&self) -> ::std::option::Option<&str> {
99        self.checksum_crc64_nvme.as_deref()
100    }
101    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 160-bit <code>SHA1</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
102    pub fn checksum_sha1(&self) -> ::std::option::Option<&str> {
103        self.checksum_sha1.as_deref()
104    }
105    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 256-bit <code>SHA256</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
106    pub fn checksum_sha256(&self) -> ::std::option::Option<&str> {
107        self.checksum_sha256.as_deref()
108    }
109    /// <p>Object key for which the multipart upload was initiated.</p>
110    pub fn key(&self) -> ::std::option::Option<&str> {
111        self.key.as_deref()
112    }
113    /// <p>Part number of part being uploaded. This is a positive integer between 1 and 10,000.</p>
114    pub fn part_number(&self) -> ::std::option::Option<i32> {
115        self.part_number
116    }
117    /// <p>Upload ID identifying the multipart upload whose part is being uploaded.</p>
118    pub fn upload_id(&self) -> ::std::option::Option<&str> {
119        self.upload_id.as_deref()
120    }
121    /// <p>Specifies the algorithm to use when encrypting the object (for example, AES256).</p><note>
122    /// <p>This functionality is not supported for directory buckets.</p>
123    /// </note>
124    pub fn sse_customer_algorithm(&self) -> ::std::option::Option<&str> {
125        self.sse_customer_algorithm.as_deref()
126    }
127    /// <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 header</code>. This must be the same encryption key specified in the initiate multipart upload request.</p><note>
128    /// <p>This functionality is not supported for directory buckets.</p>
129    /// </note>
130    pub fn sse_customer_key(&self) -> ::std::option::Option<&str> {
131        self.sse_customer_key.as_deref()
132    }
133    /// <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>
134    /// <p>This functionality is not supported for directory buckets.</p>
135    /// </note>
136    pub fn sse_customer_key_md5(&self) -> ::std::option::Option<&str> {
137        self.sse_customer_key_md5.as_deref()
138    }
139    /// <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>
140    /// <p>This functionality is not supported for directory buckets.</p>
141    /// </note>
142    pub fn request_payer(&self) -> ::std::option::Option<&crate::types::RequestPayer> {
143        self.request_payer.as_ref()
144    }
145    /// <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>
146    pub fn expected_bucket_owner(&self) -> ::std::option::Option<&str> {
147        self.expected_bucket_owner.as_deref()
148    }
149}
150impl ::std::fmt::Debug for UploadPartInput {
151    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
152        let mut formatter = f.debug_struct("UploadPartInput");
153        formatter.field("body", &self.body);
154        formatter.field("bucket", &self.bucket);
155        formatter.field("content_length", &self.content_length);
156        formatter.field("content_md5", &self.content_md5);
157        formatter.field("checksum_algorithm", &self.checksum_algorithm);
158        formatter.field("checksum_crc32", &self.checksum_crc32);
159        formatter.field("checksum_crc32_c", &self.checksum_crc32_c);
160        formatter.field("checksum_crc64_nvme", &self.checksum_crc64_nvme);
161        formatter.field("checksum_sha1", &self.checksum_sha1);
162        formatter.field("checksum_sha256", &self.checksum_sha256);
163        formatter.field("key", &self.key);
164        formatter.field("part_number", &self.part_number);
165        formatter.field("upload_id", &self.upload_id);
166        formatter.field("sse_customer_algorithm", &self.sse_customer_algorithm);
167        formatter.field("sse_customer_key", &"*** Sensitive Data Redacted ***");
168        formatter.field("sse_customer_key_md5", &self.sse_customer_key_md5);
169        formatter.field("request_payer", &self.request_payer);
170        formatter.field("expected_bucket_owner", &self.expected_bucket_owner);
171        formatter.finish()
172    }
173}
174impl UploadPartInput {
175    /// Creates a new builder-style object to manufacture [`UploadPartInput`](crate::operation::upload_part::UploadPartInput).
176    pub fn builder() -> crate::operation::upload_part::builders::UploadPartInputBuilder {
177        crate::operation::upload_part::builders::UploadPartInputBuilder::default()
178    }
179}
180
181/// A builder for [`UploadPartInput`](crate::operation::upload_part::UploadPartInput).
182#[derive(::std::default::Default)]
183#[non_exhaustive]
184pub struct UploadPartInputBuilder {
185    pub(crate) body: ::std::option::Option<::aws_smithy_types::byte_stream::ByteStream>,
186    pub(crate) bucket: ::std::option::Option<::std::string::String>,
187    pub(crate) content_length: ::std::option::Option<i64>,
188    pub(crate) content_md5: ::std::option::Option<::std::string::String>,
189    pub(crate) checksum_algorithm: ::std::option::Option<crate::types::ChecksumAlgorithm>,
190    pub(crate) checksum_crc32: ::std::option::Option<::std::string::String>,
191    pub(crate) checksum_crc32_c: ::std::option::Option<::std::string::String>,
192    pub(crate) checksum_crc64_nvme: ::std::option::Option<::std::string::String>,
193    pub(crate) checksum_sha1: ::std::option::Option<::std::string::String>,
194    pub(crate) checksum_sha256: ::std::option::Option<::std::string::String>,
195    pub(crate) key: ::std::option::Option<::std::string::String>,
196    pub(crate) part_number: ::std::option::Option<i32>,
197    pub(crate) upload_id: ::std::option::Option<::std::string::String>,
198    pub(crate) sse_customer_algorithm: ::std::option::Option<::std::string::String>,
199    pub(crate) sse_customer_key: ::std::option::Option<::std::string::String>,
200    pub(crate) sse_customer_key_md5: ::std::option::Option<::std::string::String>,
201    pub(crate) request_payer: ::std::option::Option<crate::types::RequestPayer>,
202    pub(crate) expected_bucket_owner: ::std::option::Option<::std::string::String>,
203}
204impl UploadPartInputBuilder {
205    /// <p>Object data.</p>
206    pub fn body(mut self, input: ::aws_smithy_types::byte_stream::ByteStream) -> Self {
207        self.body = ::std::option::Option::Some(input);
208        self
209    }
210    /// <p>Object data.</p>
211    pub fn set_body(mut self, input: ::std::option::Option<::aws_smithy_types::byte_stream::ByteStream>) -> Self {
212        self.body = input;
213        self
214    }
215    /// <p>Object data.</p>
216    pub fn get_body(&self) -> &::std::option::Option<::aws_smithy_types::byte_stream::ByteStream> {
217        &self.body
218    }
219    /// <p>The name of the bucket to which the multipart upload was initiated.</p>
220    /// <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>zone-id</i>.<i>region-code</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Zone (Availability Zone or Local Zone). Bucket names must follow the format <code> <i>bucket-base-name</i>--<i>zone-id</i>--x-s3</code> (for example, <code> <i>amzn-s3-demo-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>
221    /// <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>
222    /// <p>Access points and Object Lambda access points are not supported by directory buckets.</p>
223    /// </note>
224    /// <p><b>S3 on Outposts</b> - When you use this action with 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, the destination bucket must be the Outposts access point ARN or the access point alias. For more information about S3 on Outposts, 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>
225    /// This field is required.
226    pub fn bucket(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
227        self.bucket = ::std::option::Option::Some(input.into());
228        self
229    }
230    /// <p>The name of the bucket to which the multipart upload was initiated.</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>zone-id</i>.<i>region-code</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Zone (Availability Zone or Local Zone). Bucket names must follow the format <code> <i>bucket-base-name</i>--<i>zone-id</i>--x-s3</code> (for example, <code> <i>amzn-s3-demo-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 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, the destination bucket must be the Outposts access point ARN or the access point alias. For more information about S3 on Outposts, 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 set_bucket(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
237        self.bucket = input;
238        self
239    }
240    /// <p>The name of the bucket to which the multipart upload was initiated.</p>
241    /// <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>zone-id</i>.<i>region-code</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Zone (Availability Zone or Local Zone). Bucket names must follow the format <code> <i>bucket-base-name</i>--<i>zone-id</i>--x-s3</code> (for example, <code> <i>amzn-s3-demo-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>
242    /// <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>
243    /// <p>Access points and Object Lambda access points are not supported by directory buckets.</p>
244    /// </note>
245    /// <p><b>S3 on Outposts</b> - When you use this action with 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, the destination bucket must be the Outposts access point ARN or the access point alias. For more information about S3 on Outposts, 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>
246    pub fn get_bucket(&self) -> &::std::option::Option<::std::string::String> {
247        &self.bucket
248    }
249    /// <p>Size of the body in bytes. This parameter is useful when the size of the body cannot be determined automatically.</p>
250    pub fn content_length(mut self, input: i64) -> Self {
251        self.content_length = ::std::option::Option::Some(input);
252        self
253    }
254    /// <p>Size of the body in bytes. This parameter is useful when the size of the body cannot be determined automatically.</p>
255    pub fn set_content_length(mut self, input: ::std::option::Option<i64>) -> Self {
256        self.content_length = input;
257        self
258    }
259    /// <p>Size of the body in bytes. This parameter is useful when the size of the body cannot be determined automatically.</p>
260    pub fn get_content_length(&self) -> &::std::option::Option<i64> {
261        &self.content_length
262    }
263    /// <p>The Base64 encoded 128-bit MD5 digest of the part data. This parameter is auto-populated when using the command from the CLI. This parameter is required if object lock parameters are specified.</p><note>
264    /// <p>This functionality is not supported for directory buckets.</p>
265    /// </note>
266    pub fn content_md5(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
267        self.content_md5 = ::std::option::Option::Some(input.into());
268        self
269    }
270    /// <p>The Base64 encoded 128-bit MD5 digest of the part data. This parameter is auto-populated when using the command from the CLI. This parameter is required if object lock parameters are specified.</p><note>
271    /// <p>This functionality is not supported for directory buckets.</p>
272    /// </note>
273    pub fn set_content_md5(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
274        self.content_md5 = input;
275        self
276    }
277    /// <p>The Base64 encoded 128-bit MD5 digest of the part data. This parameter is auto-populated when using the command from the CLI. This parameter is required if object lock parameters are specified.</p><note>
278    /// <p>This functionality is not supported for directory buckets.</p>
279    /// </note>
280    pub fn get_content_md5(&self) -> &::std::option::Option<::std::string::String> {
281        &self.content_md5
282    }
283    /// <p>Indicates the algorithm used to create the checksum for the object when you use the SDK. This header will not provide any additional functionality if you don't use the SDK. When you send this header, there must be a corresponding <code>x-amz-checksum</code> or <code>x-amz-trailer</code> header sent. Otherwise, Amazon S3 fails the request with the HTTP status code <code>400 Bad Request</code>. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
284    /// <p>If you provide an individual checksum, Amazon S3 ignores any provided <code>ChecksumAlgorithm</code> parameter.</p>
285    /// <p>This checksum algorithm must be the same for all parts and it match the checksum value supplied in the <code>CreateMultipartUpload</code> request.</p>
286    pub fn checksum_algorithm(mut self, input: crate::types::ChecksumAlgorithm) -> Self {
287        self.checksum_algorithm = ::std::option::Option::Some(input);
288        self
289    }
290    /// <p>Indicates the algorithm used to create the checksum for the object when you use the SDK. This header will not provide any additional functionality if you don't use the SDK. When you send this header, there must be a corresponding <code>x-amz-checksum</code> or <code>x-amz-trailer</code> header sent. Otherwise, Amazon S3 fails the request with the HTTP status code <code>400 Bad Request</code>. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
291    /// <p>If you provide an individual checksum, Amazon S3 ignores any provided <code>ChecksumAlgorithm</code> parameter.</p>
292    /// <p>This checksum algorithm must be the same for all parts and it match the checksum value supplied in the <code>CreateMultipartUpload</code> request.</p>
293    pub fn set_checksum_algorithm(mut self, input: ::std::option::Option<crate::types::ChecksumAlgorithm>) -> Self {
294        self.checksum_algorithm = input;
295        self
296    }
297    /// <p>Indicates the algorithm used to create the checksum for the object when you use the SDK. This header will not provide any additional functionality if you don't use the SDK. When you send this header, there must be a corresponding <code>x-amz-checksum</code> or <code>x-amz-trailer</code> header sent. Otherwise, Amazon S3 fails the request with the HTTP status code <code>400 Bad Request</code>. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
298    /// <p>If you provide an individual checksum, Amazon S3 ignores any provided <code>ChecksumAlgorithm</code> parameter.</p>
299    /// <p>This checksum algorithm must be the same for all parts and it match the checksum value supplied in the <code>CreateMultipartUpload</code> request.</p>
300    pub fn get_checksum_algorithm(&self) -> &::std::option::Option<crate::types::ChecksumAlgorithm> {
301        &self.checksum_algorithm
302    }
303    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
304    pub fn checksum_crc32(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
305        self.checksum_crc32 = ::std::option::Option::Some(input.into());
306        self
307    }
308    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
309    pub fn set_checksum_crc32(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
310        self.checksum_crc32 = input;
311        self
312    }
313    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
314    pub fn get_checksum_crc32(&self) -> &::std::option::Option<::std::string::String> {
315        &self.checksum_crc32
316    }
317    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32C</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
318    pub fn checksum_crc32_c(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
319        self.checksum_crc32_c = ::std::option::Option::Some(input.into());
320        self
321    }
322    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32C</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
323    pub fn set_checksum_crc32_c(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
324        self.checksum_crc32_c = input;
325        self
326    }
327    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32C</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
328    pub fn get_checksum_crc32_c(&self) -> &::std::option::Option<::std::string::String> {
329        &self.checksum_crc32_c
330    }
331    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>CRC64NVME</code> checksum of the part. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
332    pub fn checksum_crc64_nvme(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
333        self.checksum_crc64_nvme = ::std::option::Option::Some(input.into());
334        self
335    }
336    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>CRC64NVME</code> checksum of the part. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
337    pub fn set_checksum_crc64_nvme(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
338        self.checksum_crc64_nvme = input;
339        self
340    }
341    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>CRC64NVME</code> checksum of the part. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
342    pub fn get_checksum_crc64_nvme(&self) -> &::std::option::Option<::std::string::String> {
343        &self.checksum_crc64_nvme
344    }
345    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 160-bit <code>SHA1</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
346    pub fn checksum_sha1(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
347        self.checksum_sha1 = ::std::option::Option::Some(input.into());
348        self
349    }
350    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 160-bit <code>SHA1</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
351    pub fn set_checksum_sha1(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
352        self.checksum_sha1 = input;
353        self
354    }
355    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 160-bit <code>SHA1</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
356    pub fn get_checksum_sha1(&self) -> &::std::option::Option<::std::string::String> {
357        &self.checksum_sha1
358    }
359    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 256-bit <code>SHA256</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
360    pub fn checksum_sha256(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
361        self.checksum_sha256 = ::std::option::Option::Some(input.into());
362        self
363    }
364    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 256-bit <code>SHA256</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
365    pub fn set_checksum_sha256(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
366        self.checksum_sha256 = input;
367        self
368    }
369    /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 256-bit <code>SHA256</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
370    pub fn get_checksum_sha256(&self) -> &::std::option::Option<::std::string::String> {
371        &self.checksum_sha256
372    }
373    /// <p>Object key for which the multipart upload was initiated.</p>
374    /// This field is required.
375    pub fn key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
376        self.key = ::std::option::Option::Some(input.into());
377        self
378    }
379    /// <p>Object key for which the multipart upload was initiated.</p>
380    pub fn set_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
381        self.key = input;
382        self
383    }
384    /// <p>Object key for which the multipart upload was initiated.</p>
385    pub fn get_key(&self) -> &::std::option::Option<::std::string::String> {
386        &self.key
387    }
388    /// <p>Part number of part being uploaded. This is a positive integer between 1 and 10,000.</p>
389    /// This field is required.
390    pub fn part_number(mut self, input: i32) -> Self {
391        self.part_number = ::std::option::Option::Some(input);
392        self
393    }
394    /// <p>Part number of part being uploaded. This is a positive integer between 1 and 10,000.</p>
395    pub fn set_part_number(mut self, input: ::std::option::Option<i32>) -> Self {
396        self.part_number = input;
397        self
398    }
399    /// <p>Part number of part being uploaded. This is a positive integer between 1 and 10,000.</p>
400    pub fn get_part_number(&self) -> &::std::option::Option<i32> {
401        &self.part_number
402    }
403    /// <p>Upload ID identifying the multipart upload whose part is being uploaded.</p>
404    /// This field is required.
405    pub fn upload_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
406        self.upload_id = ::std::option::Option::Some(input.into());
407        self
408    }
409    /// <p>Upload ID identifying the multipart upload whose part is being uploaded.</p>
410    pub fn set_upload_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
411        self.upload_id = input;
412        self
413    }
414    /// <p>Upload ID identifying the multipart upload whose part is being uploaded.</p>
415    pub fn get_upload_id(&self) -> &::std::option::Option<::std::string::String> {
416        &self.upload_id
417    }
418    /// <p>Specifies the algorithm to use when encrypting the object (for example, AES256).</p><note>
419    /// <p>This functionality is not supported for directory buckets.</p>
420    /// </note>
421    pub fn sse_customer_algorithm(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
422        self.sse_customer_algorithm = ::std::option::Option::Some(input.into());
423        self
424    }
425    /// <p>Specifies the algorithm to use when encrypting the object (for example, AES256).</p><note>
426    /// <p>This functionality is not supported for directory buckets.</p>
427    /// </note>
428    pub fn set_sse_customer_algorithm(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
429        self.sse_customer_algorithm = input;
430        self
431    }
432    /// <p>Specifies the algorithm to use when encrypting the object (for example, AES256).</p><note>
433    /// <p>This functionality is not supported for directory buckets.</p>
434    /// </note>
435    pub fn get_sse_customer_algorithm(&self) -> &::std::option::Option<::std::string::String> {
436        &self.sse_customer_algorithm
437    }
438    /// <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 header</code>. This must be the same encryption key specified in the initiate multipart upload request.</p><note>
439    /// <p>This functionality is not supported for directory buckets.</p>
440    /// </note>
441    pub fn sse_customer_key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
442        self.sse_customer_key = ::std::option::Option::Some(input.into());
443        self
444    }
445    /// <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 header</code>. This must be the same encryption key specified in the initiate multipart upload request.</p><note>
446    /// <p>This functionality is not supported for directory buckets.</p>
447    /// </note>
448    pub fn set_sse_customer_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
449        self.sse_customer_key = input;
450        self
451    }
452    /// <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 header</code>. This must be the same encryption key specified in the initiate multipart upload request.</p><note>
453    /// <p>This functionality is not supported for directory buckets.</p>
454    /// </note>
455    pub fn get_sse_customer_key(&self) -> &::std::option::Option<::std::string::String> {
456        &self.sse_customer_key
457    }
458    /// <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>
459    /// <p>This functionality is not supported for directory buckets.</p>
460    /// </note>
461    pub fn sse_customer_key_md5(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
462        self.sse_customer_key_md5 = ::std::option::Option::Some(input.into());
463        self
464    }
465    /// <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>
466    /// <p>This functionality is not supported for directory buckets.</p>
467    /// </note>
468    pub fn set_sse_customer_key_md5(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
469        self.sse_customer_key_md5 = input;
470        self
471    }
472    /// <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>
473    /// <p>This functionality is not supported for directory buckets.</p>
474    /// </note>
475    pub fn get_sse_customer_key_md5(&self) -> &::std::option::Option<::std::string::String> {
476        &self.sse_customer_key_md5
477    }
478    /// <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>
479    /// <p>This functionality is not supported for directory buckets.</p>
480    /// </note>
481    pub fn request_payer(mut self, input: crate::types::RequestPayer) -> Self {
482        self.request_payer = ::std::option::Option::Some(input);
483        self
484    }
485    /// <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>
486    /// <p>This functionality is not supported for directory buckets.</p>
487    /// </note>
488    pub fn set_request_payer(mut self, input: ::std::option::Option<crate::types::RequestPayer>) -> Self {
489        self.request_payer = input;
490        self
491    }
492    /// <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>
493    /// <p>This functionality is not supported for directory buckets.</p>
494    /// </note>
495    pub fn get_request_payer(&self) -> &::std::option::Option<crate::types::RequestPayer> {
496        &self.request_payer
497    }
498    /// <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>
499    pub fn expected_bucket_owner(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
500        self.expected_bucket_owner = ::std::option::Option::Some(input.into());
501        self
502    }
503    /// <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>
504    pub fn set_expected_bucket_owner(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
505        self.expected_bucket_owner = input;
506        self
507    }
508    /// <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>
509    pub fn get_expected_bucket_owner(&self) -> &::std::option::Option<::std::string::String> {
510        &self.expected_bucket_owner
511    }
512    /// Consumes the builder and constructs a [`UploadPartInput`](crate::operation::upload_part::UploadPartInput).
513    pub fn build(self) -> ::std::result::Result<crate::operation::upload_part::UploadPartInput, ::aws_smithy_types::error::operation::BuildError> {
514        ::std::result::Result::Ok(crate::operation::upload_part::UploadPartInput {
515            body: self.body.unwrap_or_default(),
516            bucket: self.bucket,
517            content_length: self.content_length,
518            content_md5: self.content_md5,
519            checksum_algorithm: self.checksum_algorithm,
520            checksum_crc32: self.checksum_crc32,
521            checksum_crc32_c: self.checksum_crc32_c,
522            checksum_crc64_nvme: self.checksum_crc64_nvme,
523            checksum_sha1: self.checksum_sha1,
524            checksum_sha256: self.checksum_sha256,
525            key: self.key,
526            part_number: self.part_number,
527            upload_id: self.upload_id,
528            sse_customer_algorithm: self.sse_customer_algorithm,
529            sse_customer_key: self.sse_customer_key,
530            sse_customer_key_md5: self.sse_customer_key_md5,
531            request_payer: self.request_payer,
532            expected_bucket_owner: self.expected_bucket_owner,
533        })
534    }
535}
536impl ::std::fmt::Debug for UploadPartInputBuilder {
537    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
538        let mut formatter = f.debug_struct("UploadPartInputBuilder");
539        formatter.field("body", &self.body);
540        formatter.field("bucket", &self.bucket);
541        formatter.field("content_length", &self.content_length);
542        formatter.field("content_md5", &self.content_md5);
543        formatter.field("checksum_algorithm", &self.checksum_algorithm);
544        formatter.field("checksum_crc32", &self.checksum_crc32);
545        formatter.field("checksum_crc32_c", &self.checksum_crc32_c);
546        formatter.field("checksum_crc64_nvme", &self.checksum_crc64_nvme);
547        formatter.field("checksum_sha1", &self.checksum_sha1);
548        formatter.field("checksum_sha256", &self.checksum_sha256);
549        formatter.field("key", &self.key);
550        formatter.field("part_number", &self.part_number);
551        formatter.field("upload_id", &self.upload_id);
552        formatter.field("sse_customer_algorithm", &self.sse_customer_algorithm);
553        formatter.field("sse_customer_key", &"*** Sensitive Data Redacted ***");
554        formatter.field("sse_customer_key_md5", &self.sse_customer_key_md5);
555        formatter.field("request_payer", &self.request_payer);
556        formatter.field("expected_bucket_owner", &self.expected_bucket_owner);
557        formatter.finish()
558    }
559}