// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
/// Metadata and metrics for a completed upload. Single-request uploads use `PutObject` response metadata. Multipart uploads combine `CreateMultipartUpload` initiation metadata with `CompleteMultipartUpload` metadata. Completion replaces shared fields, including absent values; initiation-only fields are retained. Optional service fields are populated only when supplied by S3. Returned bucket/key values are response metadata, not synthesized from the request. Transfer Manager supplies the completion metrics. Representing returned checksum metadata does not imply support for calculating every modeled checksum algorithm.
#[non_exhaustive]
#[derive(::std::clone::Clone)]
pub struct UploadOutput {
/// <p>If the bucket has a lifecycle rule configured with an action to abort incomplete multipart uploads and the prefix in the lifecycle rule matches the object name in the request, the response includes this header. The header indicates when the initiated multipart upload becomes eligible for an abort operation. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuoverview.html#mpu-abort-incomplete-mpu-lifecycle-config"> Aborting Incomplete Multipart Uploads Using a Bucket Lifecycle Configuration</a> in the <i>Amazon S3 User Guide</i>.</p>
/// <p>The response also includes the <code>x-amz-abort-rule-id</code> header that provides the ID of the lifecycle configuration rule that defines the abort action.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Describes lifecycle handling of an incomplete upload at initiation, not a future abort of the completed object or Transfer Manager's cancellation policy.</p>
pub abort_date: ::std::option::Option<::aws_smithy_types::DateTime>,
/// <p>This header is returned along with the <code>x-amz-abort-date</code> header. It identifies the applicable lifecycle configuration rule that defines the action to abort incomplete multipart uploads.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Describes lifecycle handling of an incomplete upload at initiation, not a future abort of the completed object or Transfer Manager's cancellation policy.</p>
pub abort_rule_id: ::std::option::Option<::std::string::String>,
/// The bucket identity returned by S3, not synthesized from the request. S3's multipart initiation documentation:
/// <p>The name of the bucket to which the multipart upload was initiated. Does not return the access point ARN or access point alias if used.</p><note>
/// <p>Access points are not supported by directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub bucket: ::std::option::Option<::std::string::String>,
/// <p>Indicates whether the uploaded object uses an S3 Bucket Key for server-side encryption with Key Management Service (KMS) keys (SSE-KMS).</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub bucket_key_enabled: ::std::option::Option<bool>,
/// <p>The algorithm that was used to create a checksum of the object.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Reports the initiation response's algorithm; it does not enable additional checksum calculation.</p>
pub checksum_algorithm: ::std::option::Option<crate::model::ChecksumAlgorithm>,
/// <p>The Base64 encoded, 32-bit <code>CRC32 checksum</code> of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub checksum_crc32: ::std::option::Option<::std::string::String>,
/// <p>The Base64 encoded, 32-bit <code>CRC32C</code> checksum of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub checksum_crc32_c: ::std::option::Option<::std::string::String>,
/// <p>The Base64 encoded, 64-bit <code>CRC64NVME</code> checksum of the object. This header is present if the object was uploaded with the <code>CRC64NVME</code> checksum algorithm, or if it was uploaded without a checksum (and Amazon S3 added the default checksum, <code>CRC64NVME</code>, to the uploaded object). For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub checksum_crc64_nvme: ::std::option::Option<::std::string::String>,
/// <p>The Base64 encoded, 128-bit <code>MD5</code> digest of the object. This header is present if the object was uploaded with the <code>MD5</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub checksum_md5: ::std::option::Option<::std::string::String>,
/// <p>The Base64 encoded, 160-bit <code>SHA1</code> digest of the object. This checksum is only present if the checksum was uploaded with the object. When you use the API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub checksum_sha1: ::std::option::Option<::std::string::String>,
/// <p>The Base64 encoded, 256-bit <code>SHA256</code> digest of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub checksum_sha256: ::std::option::Option<::std::string::String>,
/// <p>The Base64 encoded, 512-bit <code>SHA512</code> digest of the object. This header is present if the object was uploaded with the <code>SHA512</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub checksum_sha512: ::std::option::Option<::std::string::String>,
/// <p>This header specifies the checksum type of the object, which determines how part-level checksums are combined to create an object-level checksum for multipart objects. For <code>PutObject</code> uploads, the checksum type is always <code>FULL_OBJECT</code>. You can use this header as a data integrity check to verify that the checksum type that is received is the same checksum that was specified. 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>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub checksum_type: ::std::option::Option<crate::model::ChecksumType>,
/// <p>The Base64 encoded, 128-bit <code>XXHASH128</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH128</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub checksum_xxhash128: ::std::option::Option<::std::string::String>,
/// <p>The Base64 encoded, 64-bit <code>XXHASH3</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH3</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub checksum_xxhash3: ::std::option::Option<::std::string::String>,
/// <p>The Base64 encoded, 64-bit <code>XXHASH64</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH64</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub checksum_xxhash64: ::std::option::Option<::std::string::String>,
/// <p>Entity tag for the uploaded object.</p>
/// <p><b>General purpose buckets </b> - To ensure that data is not corrupted traversing the network, for objects where the ETag is the MD5 digest of the object, you can calculate the MD5 while putting an object to Amazon S3 and compare the returned ETag to the calculated MD5 value.</p>
/// <p><b>Directory buckets </b> - The ETag for the object in a directory bucket isn't the MD5 digest of the object.</p>
pub e_tag: ::std::option::Option<::std::string::String>,
/// <p>If the expiration is configured for the object (see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycleConfiguration.html">PutBucketLifecycleConfiguration</a>) in the <i>Amazon S3 User Guide</i>, the response includes this header. It includes the <code>expiry-date</code> and <code>rule-id</code> key-value pairs that provide information about object expiration. The value of the <code>rule-id</code> is URL-encoded.</p><note>
/// <p>Object expiration information is not returned in directory buckets and this header returns the value "<code>NotImplemented</code>" in all responses for directory buckets.</p>
/// </note>
pub expiration: ::std::option::Option<::std::string::String>,
/// The object key returned by S3, not synthesized from the request. S3's multipart initiation documentation:
/// <p>Object key for which the multipart upload was initiated.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub key: ::std::option::Option<::std::string::String>,
/// <p>The URI that identifies the newly created object.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>Returned in the multipart completion response.</p>
pub location: ::std::option::Option<::std::string::String>,
/// <p>If present, indicates that the requester was successfully charged for the request. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/RequesterPaysBuckets.html">Using Requester Pays buckets for storage transfers and usage</a> in the <i>Amazon Simple Storage Service user guide</i>.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
/// <p>Reports the final request's charge status, not aggregate charges for initiation and part requests.</p>
pub request_charged: ::std::option::Option<crate::model::RequestCharged>,
/// <p>If server-side encryption with a customer-provided encryption key was requested, the response will include this header to confirm the encryption algorithm that's used.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub sse_customer_algorithm: ::std::option::Option<::std::string::String>,
/// <p>If server-side encryption with a customer-provided encryption key was requested, the response will include this header to provide the round-trip message integrity verification of the customer-provided encryption key.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub sse_customer_key_md5: ::std::option::Option<::std::string::String>,
/// <p>The server-side encryption algorithm used when you store this object in Amazon S3 or Amazon FSx.</p><note>
/// <p>When accessing data stored in Amazon FSx file systems using S3 access points, the only valid server side encryption option is <code>aws:fsx</code>.</p>
/// </note>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub server_side_encryption: ::std::option::Option<crate::model::ServerSideEncryption>,
/// <p>The size of the object in bytes. This value is only be present if you append to an object.</p><note>
/// <p>This functionality is only supported for objects in the Amazon S3 Express One Zone storage class in directory buckets.</p>
/// </note>
/// <p>Only returned for single-request uploads.</p>
/// <p>This is append-only object size, not general transfer length. Transfer Manager does not initiate append uploads or populate this field from request length or transfer metrics.</p>
pub size: ::std::option::Option<i64>,
/// <p>ID for the initiated multipart upload.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub upload_id: ::std::option::Option<::std::string::String>,
/// <p>Version ID of the object.</p>
/// <p>If you enable versioning for a bucket, Amazon S3 automatically generates a unique version ID for the object being stored. Amazon S3 returns this ID in the response. When you enable versioning for a bucket, if Amazon S3 receives multiple write requests for the same object simultaneously, it stores all of the objects. For more information about versioning, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/AddingObjectstoVersioningEnabledBuckets.html">Adding Objects to Versioning-Enabled Buckets</a> in the <i>Amazon S3 User Guide</i>. For information about returning the versioning state of a bucket, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketVersioning.html">GetBucketVersioning</a>.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
pub version_id: ::std::option::Option<::std::string::String>,
/// Snapshot of transfer metrics at completion.
#[cfg(not(s3_tm_out_of_tree))]
pub metrics: crate::metrics::TransferMetrics,
/// <p>If present, indicates the Amazon Web Services KMS Encryption Context to use for object encryption. The value of this header is a Base64 encoded string of a UTF-8 encoded JSON, which contains the encryption context as key-value pairs. This value is stored as object metadata and automatically gets passed on to Amazon Web Services KMS for future <code>GetObject</code> operations on this object.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub sse_kms_encryption_context: ::std::option::Option<::std::string::String>,
/// <p>If present, indicates the ID of the KMS key that was used for object encryption.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub sse_kms_key_id: ::std::option::Option<::std::string::String>,
/// S3 request ID.
/// <p>Identifies the final request. A multipart upload reports its CompleteMultipartUpload request, and the initiation and part requests are not reported.</p>
_request_id: ::std::option::Option<::std::string::String>,
/// S3 extended request ID.
/// <p>Identifies the final request. A multipart upload reports its CompleteMultipartUpload request, and the initiation and part requests are not reported.</p>
_extended_request_id: ::std::option::Option<::std::string::String>,
}
impl UploadOutput {
/// <p>If the bucket has a lifecycle rule configured with an action to abort incomplete multipart uploads and the prefix in the lifecycle rule matches the object name in the request, the response includes this header. The header indicates when the initiated multipart upload becomes eligible for an abort operation. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuoverview.html#mpu-abort-incomplete-mpu-lifecycle-config"> Aborting Incomplete Multipart Uploads Using a Bucket Lifecycle Configuration</a> in the <i>Amazon S3 User Guide</i>.</p>
/// <p>The response also includes the <code>x-amz-abort-rule-id</code> header that provides the ID of the lifecycle configuration rule that defines the abort action.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Describes lifecycle handling of an incomplete upload at initiation, not a future abort of the completed object or Transfer Manager's cancellation policy.</p>
pub fn abort_date(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
self.abort_date.as_ref()
}
/// <p>This header is returned along with the <code>x-amz-abort-date</code> header. It identifies the applicable lifecycle configuration rule that defines the action to abort incomplete multipart uploads.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Describes lifecycle handling of an incomplete upload at initiation, not a future abort of the completed object or Transfer Manager's cancellation policy.</p>
pub fn abort_rule_id(&self) -> ::std::option::Option<&str> {
self.abort_rule_id.as_deref()
}
/// The bucket identity returned by S3, not synthesized from the request. S3's multipart initiation documentation:
/// <p>The name of the bucket to which the multipart upload was initiated. Does not return the access point ARN or access point alias if used.</p><note>
/// <p>Access points are not supported by directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn bucket(&self) -> ::std::option::Option<&str> {
self.bucket.as_deref()
}
/// <p>Indicates whether the uploaded object uses an S3 Bucket Key for server-side encryption with Key Management Service (KMS) keys (SSE-KMS).</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn bucket_key_enabled(&self) -> ::std::option::Option<bool> {
self.bucket_key_enabled
}
/// <p>The algorithm that was used to create a checksum of the object.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Reports the initiation response's algorithm; it does not enable additional checksum calculation.</p>
pub fn checksum_algorithm(&self) -> ::std::option::Option<&crate::model::ChecksumAlgorithm> {
self.checksum_algorithm.as_ref()
}
/// <p>The Base64 encoded, 32-bit <code>CRC32 checksum</code> of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn checksum_crc32(&self) -> ::std::option::Option<&str> {
self.checksum_crc32.as_deref()
}
/// <p>The Base64 encoded, 32-bit <code>CRC32C</code> checksum of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn checksum_crc32_c(&self) -> ::std::option::Option<&str> {
self.checksum_crc32_c.as_deref()
}
/// <p>The Base64 encoded, 64-bit <code>CRC64NVME</code> checksum of the object. This header is present if the object was uploaded with the <code>CRC64NVME</code> checksum algorithm, or if it was uploaded without a checksum (and Amazon S3 added the default checksum, <code>CRC64NVME</code>, to the uploaded object). For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn checksum_crc64_nvme(&self) -> ::std::option::Option<&str> {
self.checksum_crc64_nvme.as_deref()
}
/// <p>The Base64 encoded, 128-bit <code>MD5</code> digest of the object. This header is present if the object was uploaded with the <code>MD5</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn checksum_md5(&self) -> ::std::option::Option<&str> {
self.checksum_md5.as_deref()
}
/// <p>The Base64 encoded, 160-bit <code>SHA1</code> digest of the object. This checksum is only present if the checksum was uploaded with the object. When you use the API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn checksum_sha1(&self) -> ::std::option::Option<&str> {
self.checksum_sha1.as_deref()
}
/// <p>The Base64 encoded, 256-bit <code>SHA256</code> digest of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn checksum_sha256(&self) -> ::std::option::Option<&str> {
self.checksum_sha256.as_deref()
}
/// <p>The Base64 encoded, 512-bit <code>SHA512</code> digest of the object. This header is present if the object was uploaded with the <code>SHA512</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn checksum_sha512(&self) -> ::std::option::Option<&str> {
self.checksum_sha512.as_deref()
}
/// <p>This header specifies the checksum type of the object, which determines how part-level checksums are combined to create an object-level checksum for multipart objects. For <code>PutObject</code> uploads, the checksum type is always <code>FULL_OBJECT</code>. You can use this header as a data integrity check to verify that the checksum type that is received is the same checksum that was specified. 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>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn checksum_type(&self) -> ::std::option::Option<&crate::model::ChecksumType> {
self.checksum_type.as_ref()
}
/// <p>The Base64 encoded, 128-bit <code>XXHASH128</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH128</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn checksum_xxhash128(&self) -> ::std::option::Option<&str> {
self.checksum_xxhash128.as_deref()
}
/// <p>The Base64 encoded, 64-bit <code>XXHASH3</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH3</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn checksum_xxhash3(&self) -> ::std::option::Option<&str> {
self.checksum_xxhash3.as_deref()
}
/// <p>The Base64 encoded, 64-bit <code>XXHASH64</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH64</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn checksum_xxhash64(&self) -> ::std::option::Option<&str> {
self.checksum_xxhash64.as_deref()
}
/// <p>Entity tag for the uploaded object.</p>
/// <p><b>General purpose buckets </b> - To ensure that data is not corrupted traversing the network, for objects where the ETag is the MD5 digest of the object, you can calculate the MD5 while putting an object to Amazon S3 and compare the returned ETag to the calculated MD5 value.</p>
/// <p><b>Directory buckets </b> - The ETag for the object in a directory bucket isn't the MD5 digest of the object.</p>
pub fn e_tag(&self) -> ::std::option::Option<&str> {
self.e_tag.as_deref()
}
/// <p>If the expiration is configured for the object (see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycleConfiguration.html">PutBucketLifecycleConfiguration</a>) in the <i>Amazon S3 User Guide</i>, the response includes this header. It includes the <code>expiry-date</code> and <code>rule-id</code> key-value pairs that provide information about object expiration. The value of the <code>rule-id</code> is URL-encoded.</p><note>
/// <p>Object expiration information is not returned in directory buckets and this header returns the value "<code>NotImplemented</code>" in all responses for directory buckets.</p>
/// </note>
pub fn expiration(&self) -> ::std::option::Option<&str> {
self.expiration.as_deref()
}
/// The object key returned by S3, not synthesized from the request. S3's multipart initiation documentation:
/// <p>Object key for which the multipart upload was initiated.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn key(&self) -> ::std::option::Option<&str> {
self.key.as_deref()
}
/// <p>The URI that identifies the newly created object.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>Returned in the multipart completion response.</p>
pub fn location(&self) -> ::std::option::Option<&str> {
self.location.as_deref()
}
/// <p>If present, indicates that the requester was successfully charged for the request. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/RequesterPaysBuckets.html">Using Requester Pays buckets for storage transfers and usage</a> in the <i>Amazon Simple Storage Service user guide</i>.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
/// <p>Reports the final request's charge status, not aggregate charges for initiation and part requests.</p>
pub fn request_charged(&self) -> ::std::option::Option<&crate::model::RequestCharged> {
self.request_charged.as_ref()
}
/// <p>If server-side encryption with a customer-provided encryption key was requested, the response will include this header to confirm the encryption algorithm that's used.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn sse_customer_algorithm(&self) -> ::std::option::Option<&str> {
self.sse_customer_algorithm.as_deref()
}
/// <p>If server-side encryption with a customer-provided encryption key was requested, the response will include this header to provide the round-trip message integrity verification of the customer-provided encryption key.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn sse_customer_key_md5(&self) -> ::std::option::Option<&str> {
self.sse_customer_key_md5.as_deref()
}
/// <p>The server-side encryption algorithm used when you store this object in Amazon S3 or Amazon FSx.</p><note>
/// <p>When accessing data stored in Amazon FSx file systems using S3 access points, the only valid server side encryption option is <code>aws:fsx</code>.</p>
/// </note>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn server_side_encryption(
&self,
) -> ::std::option::Option<&crate::model::ServerSideEncryption> {
self.server_side_encryption.as_ref()
}
/// <p>The size of the object in bytes. This value is only be present if you append to an object.</p><note>
/// <p>This functionality is only supported for objects in the Amazon S3 Express One Zone storage class in directory buckets.</p>
/// </note>
/// <p>Only returned for single-request uploads.</p>
/// <p>This is append-only object size, not general transfer length. Transfer Manager does not initiate append uploads or populate this field from request length or transfer metrics.</p>
pub fn size(&self) -> ::std::option::Option<i64> {
self.size
}
/// <p>ID for the initiated multipart upload.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn upload_id(&self) -> ::std::option::Option<&str> {
self.upload_id.as_deref()
}
/// <p>Version ID of the object.</p>
/// <p>If you enable versioning for a bucket, Amazon S3 automatically generates a unique version ID for the object being stored. Amazon S3 returns this ID in the response. When you enable versioning for a bucket, if Amazon S3 receives multiple write requests for the same object simultaneously, it stores all of the objects. For more information about versioning, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/AddingObjectstoVersioningEnabledBuckets.html">Adding Objects to Versioning-Enabled Buckets</a> in the <i>Amazon S3 User Guide</i>. For information about returning the versioning state of a bucket, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketVersioning.html">GetBucketVersioning</a>.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
pub fn version_id(&self) -> ::std::option::Option<&str> {
self.version_id.as_deref()
}
}
impl ::std::fmt::Debug for UploadOutput {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
let mut formatter = f.debug_struct("UploadOutput");
formatter.field("abort_date", &self.abort_date);
formatter.field("abort_rule_id", &self.abort_rule_id);
formatter.field("bucket", &self.bucket);
formatter.field("bucket_key_enabled", &self.bucket_key_enabled);
formatter.field("checksum_algorithm", &self.checksum_algorithm);
formatter.field("checksum_crc32", &self.checksum_crc32);
formatter.field("checksum_crc32_c", &self.checksum_crc32_c);
formatter.field("checksum_crc64_nvme", &self.checksum_crc64_nvme);
formatter.field("checksum_md5", &self.checksum_md5);
formatter.field("checksum_sha1", &self.checksum_sha1);
formatter.field("checksum_sha256", &self.checksum_sha256);
formatter.field("checksum_sha512", &self.checksum_sha512);
formatter.field("checksum_type", &self.checksum_type);
formatter.field("checksum_xxhash128", &self.checksum_xxhash128);
formatter.field("checksum_xxhash3", &self.checksum_xxhash3);
formatter.field("checksum_xxhash64", &self.checksum_xxhash64);
formatter.field("e_tag", &self.e_tag);
formatter.field("expiration", &self.expiration);
formatter.field("key", &self.key);
formatter.field("location", &self.location);
formatter.field("request_charged", &self.request_charged);
formatter.field("sse_customer_algorithm", &self.sse_customer_algorithm);
formatter.field("sse_customer_key_md5", &self.sse_customer_key_md5);
formatter.field("server_side_encryption", &self.server_side_encryption);
formatter.field("size", &self.size);
formatter.field("upload_id", &self.upload_id);
formatter.field("version_id", &self.version_id);
formatter.field(
"sse_kms_encryption_context",
&"*** Sensitive Data Redacted ***",
);
formatter.field("sse_kms_key_id", &"*** Sensitive Data Redacted ***");
formatter.field("_request_id", &self._request_id);
formatter.field("_extended_request_id", &self._extended_request_id);
formatter.finish()
}
}
impl crate::model::UploadOutput {
/// Snapshot of transfer metrics at completion.
#[cfg(not(s3_tm_out_of_tree))]
pub fn metrics(&self) -> &crate::metrics::TransferMetrics {
&self.metrics
}
/// <p>If present, indicates the Amazon Web Services KMS Encryption Context to use for object encryption. The value of this header is a Base64 encoded string of a UTF-8 encoded JSON, which contains the encryption context as key-value pairs. This value is stored as object metadata and automatically gets passed on to Amazon Web Services KMS for future <code>GetObject</code> operations on this object.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn sse_kms_encryption_context(&self) -> ::std::option::Option<&str> {
self.sse_kms_encryption_context.as_deref()
}
/// <p>If present, indicates the ID of the KMS key that was used for object encryption.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn sse_kms_key_id(&self) -> ::std::option::Option<&str> {
self.sse_kms_key_id.as_deref()
}
/// S3 request ID.
/// <p>Identifies the final request. A multipart upload reports its CompleteMultipartUpload request, and the initiation and part requests are not reported.</p>
pub fn request_id(&self) -> ::std::option::Option<&str> {
self._request_id.as_deref()
}
/// S3 extended request ID.
/// <p>Identifies the final request. A multipart upload reports its CompleteMultipartUpload request, and the initiation and part requests are not reported.</p>
pub fn extended_request_id(&self) -> ::std::option::Option<&str> {
self._extended_request_id.as_deref()
}
}
impl UploadOutput {
/// Creates a new builder-style object to manufacture [`UploadOutput`](crate::model::UploadOutput).
pub fn builder() -> crate::model::builders::UploadOutputBuilder {
crate::model::builders::UploadOutputBuilder::default()
}
}
/// A builder for [`UploadOutput`](crate::model::UploadOutput).
#[derive(::std::clone::Clone, ::std::default::Default)]
#[non_exhaustive]
pub struct UploadOutputBuilder {
pub(crate) abort_date: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) abort_rule_id: ::std::option::Option<::std::string::String>,
pub(crate) bucket: ::std::option::Option<::std::string::String>,
pub(crate) bucket_key_enabled: ::std::option::Option<bool>,
pub(crate) checksum_algorithm: ::std::option::Option<crate::model::ChecksumAlgorithm>,
pub(crate) checksum_crc32: ::std::option::Option<::std::string::String>,
pub(crate) checksum_crc32_c: ::std::option::Option<::std::string::String>,
pub(crate) checksum_crc64_nvme: ::std::option::Option<::std::string::String>,
pub(crate) checksum_md5: ::std::option::Option<::std::string::String>,
pub(crate) checksum_sha1: ::std::option::Option<::std::string::String>,
pub(crate) checksum_sha256: ::std::option::Option<::std::string::String>,
pub(crate) checksum_sha512: ::std::option::Option<::std::string::String>,
pub(crate) checksum_type: ::std::option::Option<crate::model::ChecksumType>,
pub(crate) checksum_xxhash128: ::std::option::Option<::std::string::String>,
pub(crate) checksum_xxhash3: ::std::option::Option<::std::string::String>,
pub(crate) checksum_xxhash64: ::std::option::Option<::std::string::String>,
pub(crate) e_tag: ::std::option::Option<::std::string::String>,
pub(crate) expiration: ::std::option::Option<::std::string::String>,
pub(crate) key: ::std::option::Option<::std::string::String>,
pub(crate) location: ::std::option::Option<::std::string::String>,
pub(crate) request_charged: ::std::option::Option<crate::model::RequestCharged>,
pub(crate) sse_customer_algorithm: ::std::option::Option<::std::string::String>,
pub(crate) sse_customer_key_md5: ::std::option::Option<::std::string::String>,
pub(crate) server_side_encryption: ::std::option::Option<crate::model::ServerSideEncryption>,
pub(crate) size: ::std::option::Option<i64>,
pub(crate) upload_id: ::std::option::Option<::std::string::String>,
pub(crate) version_id: ::std::option::Option<::std::string::String>,
#[cfg(not(s3_tm_out_of_tree))]
pub(crate) metrics: ::std::option::Option<crate::metrics::TransferMetrics>,
pub(crate) sse_kms_encryption_context: ::std::option::Option<::std::string::String>,
pub(crate) sse_kms_key_id: ::std::option::Option<::std::string::String>,
pub(crate) _request_id: ::std::option::Option<::std::string::String>,
pub(crate) _extended_request_id: ::std::option::Option<::std::string::String>,
}
impl UploadOutputBuilder {
/// <p>If the bucket has a lifecycle rule configured with an action to abort incomplete multipart uploads and the prefix in the lifecycle rule matches the object name in the request, the response includes this header. The header indicates when the initiated multipart upload becomes eligible for an abort operation. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuoverview.html#mpu-abort-incomplete-mpu-lifecycle-config"> Aborting Incomplete Multipart Uploads Using a Bucket Lifecycle Configuration</a> in the <i>Amazon S3 User Guide</i>.</p>
/// <p>The response also includes the <code>x-amz-abort-rule-id</code> header that provides the ID of the lifecycle configuration rule that defines the abort action.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Describes lifecycle handling of an incomplete upload at initiation, not a future abort of the completed object or Transfer Manager's cancellation policy.</p>
pub fn abort_date(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.abort_date = ::std::option::Option::Some(input);
self
}
/// <p>If the bucket has a lifecycle rule configured with an action to abort incomplete multipart uploads and the prefix in the lifecycle rule matches the object name in the request, the response includes this header. The header indicates when the initiated multipart upload becomes eligible for an abort operation. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuoverview.html#mpu-abort-incomplete-mpu-lifecycle-config"> Aborting Incomplete Multipart Uploads Using a Bucket Lifecycle Configuration</a> in the <i>Amazon S3 User Guide</i>.</p>
/// <p>The response also includes the <code>x-amz-abort-rule-id</code> header that provides the ID of the lifecycle configuration rule that defines the abort action.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Describes lifecycle handling of an incomplete upload at initiation, not a future abort of the completed object or Transfer Manager's cancellation policy.</p>
pub fn set_abort_date(
mut self,
input: ::std::option::Option<::aws_smithy_types::DateTime>,
) -> Self {
self.abort_date = input;
self
}
/// <p>If the bucket has a lifecycle rule configured with an action to abort incomplete multipart uploads and the prefix in the lifecycle rule matches the object name in the request, the response includes this header. The header indicates when the initiated multipart upload becomes eligible for an abort operation. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/mpuoverview.html#mpu-abort-incomplete-mpu-lifecycle-config"> Aborting Incomplete Multipart Uploads Using a Bucket Lifecycle Configuration</a> in the <i>Amazon S3 User Guide</i>.</p>
/// <p>The response also includes the <code>x-amz-abort-rule-id</code> header that provides the ID of the lifecycle configuration rule that defines the abort action.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Describes lifecycle handling of an incomplete upload at initiation, not a future abort of the completed object or Transfer Manager's cancellation policy.</p>
pub fn get_abort_date(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.abort_date
}
/// <p>This header is returned along with the <code>x-amz-abort-date</code> header. It identifies the applicable lifecycle configuration rule that defines the action to abort incomplete multipart uploads.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Describes lifecycle handling of an incomplete upload at initiation, not a future abort of the completed object or Transfer Manager's cancellation policy.</p>
pub fn abort_rule_id(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.abort_rule_id = ::std::option::Option::Some(input.into());
self
}
/// <p>This header is returned along with the <code>x-amz-abort-date</code> header. It identifies the applicable lifecycle configuration rule that defines the action to abort incomplete multipart uploads.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Describes lifecycle handling of an incomplete upload at initiation, not a future abort of the completed object or Transfer Manager's cancellation policy.</p>
pub fn set_abort_rule_id(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.abort_rule_id = input;
self
}
/// <p>This header is returned along with the <code>x-amz-abort-date</code> header. It identifies the applicable lifecycle configuration rule that defines the action to abort incomplete multipart uploads.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Describes lifecycle handling of an incomplete upload at initiation, not a future abort of the completed object or Transfer Manager's cancellation policy.</p>
pub fn get_abort_rule_id(&self) -> &::std::option::Option<::std::string::String> {
&self.abort_rule_id
}
/// The bucket identity returned by S3, not synthesized from the request. S3's multipart initiation documentation:
/// <p>The name of the bucket to which the multipart upload was initiated. Does not return the access point ARN or access point alias if used.</p><note>
/// <p>Access points are not supported by directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn bucket(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.bucket = ::std::option::Option::Some(input.into());
self
}
/// The bucket identity returned by S3, not synthesized from the request. S3's multipart initiation documentation:
/// <p>The name of the bucket to which the multipart upload was initiated. Does not return the access point ARN or access point alias if used.</p><note>
/// <p>Access points are not supported by directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn set_bucket(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.bucket = input;
self
}
/// The bucket identity returned by S3, not synthesized from the request. S3's multipart initiation documentation:
/// <p>The name of the bucket to which the multipart upload was initiated. Does not return the access point ARN or access point alias if used.</p><note>
/// <p>Access points are not supported by directory buckets.</p>
/// </note>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn get_bucket(&self) -> &::std::option::Option<::std::string::String> {
&self.bucket
}
/// <p>Indicates whether the uploaded object uses an S3 Bucket Key for server-side encryption with Key Management Service (KMS) keys (SSE-KMS).</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn bucket_key_enabled(mut self, input: bool) -> Self {
self.bucket_key_enabled = ::std::option::Option::Some(input);
self
}
/// <p>Indicates whether the uploaded object uses an S3 Bucket Key for server-side encryption with Key Management Service (KMS) keys (SSE-KMS).</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn set_bucket_key_enabled(mut self, input: ::std::option::Option<bool>) -> Self {
self.bucket_key_enabled = input;
self
}
/// <p>Indicates whether the uploaded object uses an S3 Bucket Key for server-side encryption with Key Management Service (KMS) keys (SSE-KMS).</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn get_bucket_key_enabled(&self) -> &::std::option::Option<bool> {
&self.bucket_key_enabled
}
/// <p>The algorithm that was used to create a checksum of the object.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Reports the initiation response's algorithm; it does not enable additional checksum calculation.</p>
pub fn checksum_algorithm(mut self, input: crate::model::ChecksumAlgorithm) -> Self {
self.checksum_algorithm = ::std::option::Option::Some(input);
self
}
/// <p>The algorithm that was used to create a checksum of the object.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Reports the initiation response's algorithm; it does not enable additional checksum calculation.</p>
pub fn set_checksum_algorithm(
mut self,
input: ::std::option::Option<crate::model::ChecksumAlgorithm>,
) -> Self {
self.checksum_algorithm = input;
self
}
/// <p>The algorithm that was used to create a checksum of the object.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
/// <p>Reports the initiation response's algorithm; it does not enable additional checksum calculation.</p>
pub fn get_checksum_algorithm(
&self,
) -> &::std::option::Option<crate::model::ChecksumAlgorithm> {
&self.checksum_algorithm
}
/// <p>The Base64 encoded, 32-bit <code>CRC32 checksum</code> of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn checksum_crc32(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.checksum_crc32 = ::std::option::Option::Some(input.into());
self
}
/// <p>The Base64 encoded, 32-bit <code>CRC32 checksum</code> of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn set_checksum_crc32(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.checksum_crc32 = input;
self
}
/// <p>The Base64 encoded, 32-bit <code>CRC32 checksum</code> of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn get_checksum_crc32(&self) -> &::std::option::Option<::std::string::String> {
&self.checksum_crc32
}
/// <p>The Base64 encoded, 32-bit <code>CRC32C</code> checksum of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn checksum_crc32_c(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.checksum_crc32_c = ::std::option::Option::Some(input.into());
self
}
/// <p>The Base64 encoded, 32-bit <code>CRC32C</code> checksum of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn set_checksum_crc32_c(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.checksum_crc32_c = input;
self
}
/// <p>The Base64 encoded, 32-bit <code>CRC32C</code> checksum of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn get_checksum_crc32_c(&self) -> &::std::option::Option<::std::string::String> {
&self.checksum_crc32_c
}
/// <p>The Base64 encoded, 64-bit <code>CRC64NVME</code> checksum of the object. This header is present if the object was uploaded with the <code>CRC64NVME</code> checksum algorithm, or if it was uploaded without a checksum (and Amazon S3 added the default checksum, <code>CRC64NVME</code>, to the uploaded object). For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn checksum_crc64_nvme(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.checksum_crc64_nvme = ::std::option::Option::Some(input.into());
self
}
/// <p>The Base64 encoded, 64-bit <code>CRC64NVME</code> checksum of the object. This header is present if the object was uploaded with the <code>CRC64NVME</code> checksum algorithm, or if it was uploaded without a checksum (and Amazon S3 added the default checksum, <code>CRC64NVME</code>, to the uploaded object). For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn set_checksum_crc64_nvme(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.checksum_crc64_nvme = input;
self
}
/// <p>The Base64 encoded, 64-bit <code>CRC64NVME</code> checksum of the object. This header is present if the object was uploaded with the <code>CRC64NVME</code> checksum algorithm, or if it was uploaded without a checksum (and Amazon S3 added the default checksum, <code>CRC64NVME</code>, to the uploaded object). For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn get_checksum_crc64_nvme(&self) -> &::std::option::Option<::std::string::String> {
&self.checksum_crc64_nvme
}
/// <p>The Base64 encoded, 128-bit <code>MD5</code> digest of the object. This header is present if the object was uploaded with the <code>MD5</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn checksum_md5(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.checksum_md5 = ::std::option::Option::Some(input.into());
self
}
/// <p>The Base64 encoded, 128-bit <code>MD5</code> digest of the object. This header is present if the object was uploaded with the <code>MD5</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn set_checksum_md5(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.checksum_md5 = input;
self
}
/// <p>The Base64 encoded, 128-bit <code>MD5</code> digest of the object. This header is present if the object was uploaded with the <code>MD5</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn get_checksum_md5(&self) -> &::std::option::Option<::std::string::String> {
&self.checksum_md5
}
/// <p>The Base64 encoded, 160-bit <code>SHA1</code> digest of the object. This checksum is only present if the checksum was uploaded with the object. When you use the API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn checksum_sha1(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.checksum_sha1 = ::std::option::Option::Some(input.into());
self
}
/// <p>The Base64 encoded, 160-bit <code>SHA1</code> digest of the object. This checksum is only present if the checksum was uploaded with the object. When you use the API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn set_checksum_sha1(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.checksum_sha1 = input;
self
}
/// <p>The Base64 encoded, 160-bit <code>SHA1</code> digest of the object. This checksum is only present if the checksum was uploaded with the object. When you use the API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn get_checksum_sha1(&self) -> &::std::option::Option<::std::string::String> {
&self.checksum_sha1
}
/// <p>The Base64 encoded, 256-bit <code>SHA256</code> digest of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn checksum_sha256(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.checksum_sha256 = ::std::option::Option::Some(input.into());
self
}
/// <p>The Base64 encoded, 256-bit <code>SHA256</code> digest of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn set_checksum_sha256(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.checksum_sha256 = input;
self
}
/// <p>The Base64 encoded, 256-bit <code>SHA256</code> digest of the object. This checksum is only present if the checksum was uploaded with the object. When you use an API operation on an object that was uploaded using multipart uploads, this value may not be a direct checksum value of the full object. Instead, it's a calculation based on the checksum values of each individual part. For more information about how checksums are calculated with multipart uploads, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html#large-object-checksums"> Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
pub fn get_checksum_sha256(&self) -> &::std::option::Option<::std::string::String> {
&self.checksum_sha256
}
/// <p>The Base64 encoded, 512-bit <code>SHA512</code> digest of the object. This header is present if the object was uploaded with the <code>SHA512</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn checksum_sha512(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.checksum_sha512 = ::std::option::Option::Some(input.into());
self
}
/// <p>The Base64 encoded, 512-bit <code>SHA512</code> digest of the object. This header is present if the object was uploaded with the <code>SHA512</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn set_checksum_sha512(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.checksum_sha512 = input;
self
}
/// <p>The Base64 encoded, 512-bit <code>SHA512</code> digest of the object. This header is present if the object was uploaded with the <code>SHA512</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn get_checksum_sha512(&self) -> &::std::option::Option<::std::string::String> {
&self.checksum_sha512
}
/// <p>This header specifies the checksum type of the object, which determines how part-level checksums are combined to create an object-level checksum for multipart objects. For <code>PutObject</code> uploads, the checksum type is always <code>FULL_OBJECT</code>. You can use this header as a data integrity check to verify that the checksum type that is received is the same checksum that was specified. 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>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn checksum_type(mut self, input: crate::model::ChecksumType) -> Self {
self.checksum_type = ::std::option::Option::Some(input);
self
}
/// <p>This header specifies the checksum type of the object, which determines how part-level checksums are combined to create an object-level checksum for multipart objects. For <code>PutObject</code> uploads, the checksum type is always <code>FULL_OBJECT</code>. You can use this header as a data integrity check to verify that the checksum type that is received is the same checksum that was specified. 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>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn set_checksum_type(
mut self,
input: ::std::option::Option<crate::model::ChecksumType>,
) -> Self {
self.checksum_type = input;
self
}
/// <p>This header specifies the checksum type of the object, which determines how part-level checksums are combined to create an object-level checksum for multipart objects. For <code>PutObject</code> uploads, the checksum type is always <code>FULL_OBJECT</code>. You can use this header as a data integrity check to verify that the checksum type that is received is the same checksum that was specified. 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>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn get_checksum_type(&self) -> &::std::option::Option<crate::model::ChecksumType> {
&self.checksum_type
}
/// <p>The Base64 encoded, 128-bit <code>XXHASH128</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH128</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn checksum_xxhash128(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.checksum_xxhash128 = ::std::option::Option::Some(input.into());
self
}
/// <p>The Base64 encoded, 128-bit <code>XXHASH128</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH128</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn set_checksum_xxhash128(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.checksum_xxhash128 = input;
self
}
/// <p>The Base64 encoded, 128-bit <code>XXHASH128</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH128</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn get_checksum_xxhash128(&self) -> &::std::option::Option<::std::string::String> {
&self.checksum_xxhash128
}
/// <p>The Base64 encoded, 64-bit <code>XXHASH3</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH3</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn checksum_xxhash3(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.checksum_xxhash3 = ::std::option::Option::Some(input.into());
self
}
/// <p>The Base64 encoded, 64-bit <code>XXHASH3</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH3</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn set_checksum_xxhash3(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.checksum_xxhash3 = input;
self
}
/// <p>The Base64 encoded, 64-bit <code>XXHASH3</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH3</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn get_checksum_xxhash3(&self) -> &::std::option::Option<::std::string::String> {
&self.checksum_xxhash3
}
/// <p>The Base64 encoded, 64-bit <code>XXHASH64</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH64</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn checksum_xxhash64(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.checksum_xxhash64 = ::std::option::Option::Some(input.into());
self
}
/// <p>The Base64 encoded, 64-bit <code>XXHASH64</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH64</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn set_checksum_xxhash64(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.checksum_xxhash64 = input;
self
}
/// <p>The Base64 encoded, 64-bit <code>XXHASH64</code> checksum of the object. This header is present if the object was uploaded with the <code>XXHASH64</code> checksum algorithm. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
pub fn get_checksum_xxhash64(&self) -> &::std::option::Option<::std::string::String> {
&self.checksum_xxhash64
}
/// <p>Entity tag for the uploaded object.</p>
/// <p><b>General purpose buckets </b> - To ensure that data is not corrupted traversing the network, for objects where the ETag is the MD5 digest of the object, you can calculate the MD5 while putting an object to Amazon S3 and compare the returned ETag to the calculated MD5 value.</p>
/// <p><b>Directory buckets </b> - The ETag for the object in a directory bucket isn't the MD5 digest of the object.</p>
pub fn e_tag(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.e_tag = ::std::option::Option::Some(input.into());
self
}
/// <p>Entity tag for the uploaded object.</p>
/// <p><b>General purpose buckets </b> - To ensure that data is not corrupted traversing the network, for objects where the ETag is the MD5 digest of the object, you can calculate the MD5 while putting an object to Amazon S3 and compare the returned ETag to the calculated MD5 value.</p>
/// <p><b>Directory buckets </b> - The ETag for the object in a directory bucket isn't the MD5 digest of the object.</p>
pub fn set_e_tag(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.e_tag = input;
self
}
/// <p>Entity tag for the uploaded object.</p>
/// <p><b>General purpose buckets </b> - To ensure that data is not corrupted traversing the network, for objects where the ETag is the MD5 digest of the object, you can calculate the MD5 while putting an object to Amazon S3 and compare the returned ETag to the calculated MD5 value.</p>
/// <p><b>Directory buckets </b> - The ETag for the object in a directory bucket isn't the MD5 digest of the object.</p>
pub fn get_e_tag(&self) -> &::std::option::Option<::std::string::String> {
&self.e_tag
}
/// <p>If the expiration is configured for the object (see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycleConfiguration.html">PutBucketLifecycleConfiguration</a>) in the <i>Amazon S3 User Guide</i>, the response includes this header. It includes the <code>expiry-date</code> and <code>rule-id</code> key-value pairs that provide information about object expiration. The value of the <code>rule-id</code> is URL-encoded.</p><note>
/// <p>Object expiration information is not returned in directory buckets and this header returns the value "<code>NotImplemented</code>" in all responses for directory buckets.</p>
/// </note>
pub fn expiration(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.expiration = ::std::option::Option::Some(input.into());
self
}
/// <p>If the expiration is configured for the object (see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycleConfiguration.html">PutBucketLifecycleConfiguration</a>) in the <i>Amazon S3 User Guide</i>, the response includes this header. It includes the <code>expiry-date</code> and <code>rule-id</code> key-value pairs that provide information about object expiration. The value of the <code>rule-id</code> is URL-encoded.</p><note>
/// <p>Object expiration information is not returned in directory buckets and this header returns the value "<code>NotImplemented</code>" in all responses for directory buckets.</p>
/// </note>
pub fn set_expiration(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.expiration = input;
self
}
/// <p>If the expiration is configured for the object (see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycleConfiguration.html">PutBucketLifecycleConfiguration</a>) in the <i>Amazon S3 User Guide</i>, the response includes this header. It includes the <code>expiry-date</code> and <code>rule-id</code> key-value pairs that provide information about object expiration. The value of the <code>rule-id</code> is URL-encoded.</p><note>
/// <p>Object expiration information is not returned in directory buckets and this header returns the value "<code>NotImplemented</code>" in all responses for directory buckets.</p>
/// </note>
pub fn get_expiration(&self) -> &::std::option::Option<::std::string::String> {
&self.expiration
}
/// The object key returned by S3, not synthesized from the request. S3's multipart initiation documentation:
/// <p>Object key for which the multipart upload was initiated.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.key = ::std::option::Option::Some(input.into());
self
}
/// The object key returned by S3, not synthesized from the request. S3's multipart initiation documentation:
/// <p>Object key for which the multipart upload was initiated.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn set_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.key = input;
self
}
/// The object key returned by S3, not synthesized from the request. S3's multipart initiation documentation:
/// <p>Object key for which the multipart upload was initiated.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn get_key(&self) -> &::std::option::Option<::std::string::String> {
&self.key
}
/// <p>The URI that identifies the newly created object.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>Returned in the multipart completion response.</p>
pub fn location(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.location = ::std::option::Option::Some(input.into());
self
}
/// <p>The URI that identifies the newly created object.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>Returned in the multipart completion response.</p>
pub fn set_location(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.location = input;
self
}
/// <p>The URI that identifies the newly created object.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>Returned in the multipart completion response.</p>
pub fn get_location(&self) -> &::std::option::Option<::std::string::String> {
&self.location
}
/// <p>If present, indicates that the requester was successfully charged for the request. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/RequesterPaysBuckets.html">Using Requester Pays buckets for storage transfers and usage</a> in the <i>Amazon Simple Storage Service user guide</i>.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
/// <p>Reports the final request's charge status, not aggregate charges for initiation and part requests.</p>
pub fn request_charged(mut self, input: crate::model::RequestCharged) -> Self {
self.request_charged = ::std::option::Option::Some(input);
self
}
/// <p>If present, indicates that the requester was successfully charged for the request. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/RequesterPaysBuckets.html">Using Requester Pays buckets for storage transfers and usage</a> in the <i>Amazon Simple Storage Service user guide</i>.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
/// <p>Reports the final request's charge status, not aggregate charges for initiation and part requests.</p>
pub fn set_request_charged(
mut self,
input: ::std::option::Option<crate::model::RequestCharged>,
) -> Self {
self.request_charged = input;
self
}
/// <p>If present, indicates that the requester was successfully charged for the request. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/RequesterPaysBuckets.html">Using Requester Pays buckets for storage transfers and usage</a> in the <i>Amazon Simple Storage Service user guide</i>.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
/// <p>Reports the final request's charge status, not aggregate charges for initiation and part requests.</p>
pub fn get_request_charged(&self) -> &::std::option::Option<crate::model::RequestCharged> {
&self.request_charged
}
/// <p>If server-side encryption with a customer-provided encryption key was requested, the response will include this header to confirm the encryption algorithm that's used.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn sse_customer_algorithm(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.sse_customer_algorithm = ::std::option::Option::Some(input.into());
self
}
/// <p>If server-side encryption with a customer-provided encryption key was requested, the response will include this header to confirm the encryption algorithm that's used.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn set_sse_customer_algorithm(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.sse_customer_algorithm = input;
self
}
/// <p>If server-side encryption with a customer-provided encryption key was requested, the response will include this header to confirm the encryption algorithm that's used.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn get_sse_customer_algorithm(&self) -> &::std::option::Option<::std::string::String> {
&self.sse_customer_algorithm
}
/// <p>If server-side encryption with a customer-provided encryption key was requested, the response will include this header to provide the round-trip message integrity verification of the customer-provided encryption key.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn sse_customer_key_md5(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.sse_customer_key_md5 = ::std::option::Option::Some(input.into());
self
}
/// <p>If server-side encryption with a customer-provided encryption key was requested, the response will include this header to provide the round-trip message integrity verification of the customer-provided encryption key.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn set_sse_customer_key_md5(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.sse_customer_key_md5 = input;
self
}
/// <p>If server-side encryption with a customer-provided encryption key was requested, the response will include this header to provide the round-trip message integrity verification of the customer-provided encryption key.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn get_sse_customer_key_md5(&self) -> &::std::option::Option<::std::string::String> {
&self.sse_customer_key_md5
}
/// <p>The server-side encryption algorithm used when you store this object in Amazon S3 or Amazon FSx.</p><note>
/// <p>When accessing data stored in Amazon FSx file systems using S3 access points, the only valid server side encryption option is <code>aws:fsx</code>.</p>
/// </note>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn server_side_encryption(mut self, input: crate::model::ServerSideEncryption) -> Self {
self.server_side_encryption = ::std::option::Option::Some(input);
self
}
/// <p>The server-side encryption algorithm used when you store this object in Amazon S3 or Amazon FSx.</p><note>
/// <p>When accessing data stored in Amazon FSx file systems using S3 access points, the only valid server side encryption option is <code>aws:fsx</code>.</p>
/// </note>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn set_server_side_encryption(
mut self,
input: ::std::option::Option<crate::model::ServerSideEncryption>,
) -> Self {
self.server_side_encryption = input;
self
}
/// <p>The server-side encryption algorithm used when you store this object in Amazon S3 or Amazon FSx.</p><note>
/// <p>When accessing data stored in Amazon FSx file systems using S3 access points, the only valid server side encryption option is <code>aws:fsx</code>.</p>
/// </note>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn get_server_side_encryption(
&self,
) -> &::std::option::Option<crate::model::ServerSideEncryption> {
&self.server_side_encryption
}
/// <p>The size of the object in bytes. This value is only be present if you append to an object.</p><note>
/// <p>This functionality is only supported for objects in the Amazon S3 Express One Zone storage class in directory buckets.</p>
/// </note>
/// <p>Only returned for single-request uploads.</p>
/// <p>This is append-only object size, not general transfer length. Transfer Manager does not initiate append uploads or populate this field from request length or transfer metrics.</p>
pub fn size(mut self, input: i64) -> Self {
self.size = ::std::option::Option::Some(input);
self
}
/// <p>The size of the object in bytes. This value is only be present if you append to an object.</p><note>
/// <p>This functionality is only supported for objects in the Amazon S3 Express One Zone storage class in directory buckets.</p>
/// </note>
/// <p>Only returned for single-request uploads.</p>
/// <p>This is append-only object size, not general transfer length. Transfer Manager does not initiate append uploads or populate this field from request length or transfer metrics.</p>
pub fn set_size(mut self, input: ::std::option::Option<i64>) -> Self {
self.size = input;
self
}
/// <p>The size of the object in bytes. This value is only be present if you append to an object.</p><note>
/// <p>This functionality is only supported for objects in the Amazon S3 Express One Zone storage class in directory buckets.</p>
/// </note>
/// <p>Only returned for single-request uploads.</p>
/// <p>This is append-only object size, not general transfer length. Transfer Manager does not initiate append uploads or populate this field from request length or transfer metrics.</p>
pub fn get_size(&self) -> &::std::option::Option<i64> {
&self.size
}
/// <p>ID for the initiated multipart upload.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn upload_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.upload_id = ::std::option::Option::Some(input.into());
self
}
/// <p>ID for the initiated multipart upload.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn set_upload_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.upload_id = input;
self
}
/// <p>ID for the initiated multipart upload.</p>
/// <p>Not returned for single-request uploads.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn get_upload_id(&self) -> &::std::option::Option<::std::string::String> {
&self.upload_id
}
/// <p>Version ID of the object.</p>
/// <p>If you enable versioning for a bucket, Amazon S3 automatically generates a unique version ID for the object being stored. Amazon S3 returns this ID in the response. When you enable versioning for a bucket, if Amazon S3 receives multiple write requests for the same object simultaneously, it stores all of the objects. For more information about versioning, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/AddingObjectstoVersioningEnabledBuckets.html">Adding Objects to Versioning-Enabled Buckets</a> in the <i>Amazon S3 User Guide</i>. For information about returning the versioning state of a bucket, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketVersioning.html">GetBucketVersioning</a>.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
pub fn version_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.version_id = ::std::option::Option::Some(input.into());
self
}
/// <p>Version ID of the object.</p>
/// <p>If you enable versioning for a bucket, Amazon S3 automatically generates a unique version ID for the object being stored. Amazon S3 returns this ID in the response. When you enable versioning for a bucket, if Amazon S3 receives multiple write requests for the same object simultaneously, it stores all of the objects. For more information about versioning, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/AddingObjectstoVersioningEnabledBuckets.html">Adding Objects to Versioning-Enabled Buckets</a> in the <i>Amazon S3 User Guide</i>. For information about returning the versioning state of a bucket, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketVersioning.html">GetBucketVersioning</a>.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
pub fn set_version_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.version_id = input;
self
}
/// <p>Version ID of the object.</p>
/// <p>If you enable versioning for a bucket, Amazon S3 automatically generates a unique version ID for the object being stored. Amazon S3 returns this ID in the response. When you enable versioning for a bucket, if Amazon S3 receives multiple write requests for the same object simultaneously, it stores all of the objects. For more information about versioning, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/AddingObjectstoVersioningEnabledBuckets.html">Adding Objects to Versioning-Enabled Buckets</a> in the <i>Amazon S3 User Guide</i>. For information about returning the versioning state of a bucket, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketVersioning.html">GetBucketVersioning</a>.</p><note>
/// <p>This functionality is not supported for directory buckets.</p>
/// </note>
pub fn get_version_id(&self) -> &::std::option::Option<::std::string::String> {
&self.version_id
}
/// Snapshot of transfer metrics at completion.
#[cfg(not(s3_tm_out_of_tree))]
#[allow(dead_code)]
pub(crate) fn metrics(mut self, input: crate::metrics::TransferMetrics) -> Self {
self.metrics = ::std::option::Option::Some(input);
self
}
/// Snapshot of transfer metrics at completion.
#[cfg(not(s3_tm_out_of_tree))]
#[allow(dead_code)]
pub(crate) fn set_metrics(
mut self,
input: ::std::option::Option<crate::metrics::TransferMetrics>,
) -> Self {
self.metrics = input;
self
}
/// Snapshot of transfer metrics at completion.
#[cfg(not(s3_tm_out_of_tree))]
#[allow(dead_code)]
pub(crate) fn get_metrics(&self) -> &::std::option::Option<crate::metrics::TransferMetrics> {
&self.metrics
}
/// <p>If present, indicates the Amazon Web Services KMS Encryption Context to use for object encryption. The value of this header is a Base64 encoded string of a UTF-8 encoded JSON, which contains the encryption context as key-value pairs. This value is stored as object metadata and automatically gets passed on to Amazon Web Services KMS for future <code>GetObject</code> operations on this object.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn sse_kms_encryption_context(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.sse_kms_encryption_context = ::std::option::Option::Some(input.into());
self
}
/// <p>If present, indicates the Amazon Web Services KMS Encryption Context to use for object encryption. The value of this header is a Base64 encoded string of a UTF-8 encoded JSON, which contains the encryption context as key-value pairs. This value is stored as object metadata and automatically gets passed on to Amazon Web Services KMS for future <code>GetObject</code> operations on this object.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn set_sse_kms_encryption_context(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.sse_kms_encryption_context = input;
self
}
/// <p>If present, indicates the Amazon Web Services KMS Encryption Context to use for object encryption. The value of this header is a Base64 encoded string of a UTF-8 encoded JSON, which contains the encryption context as key-value pairs. This value is stored as object metadata and automatically gets passed on to Amazon Web Services KMS for future <code>GetObject</code> operations on this object.</p>
/// <p>For multipart uploads, retained from the initiation response after successful completion.</p>
pub fn get_sse_kms_encryption_context(&self) -> &::std::option::Option<::std::string::String> {
&self.sse_kms_encryption_context
}
/// <p>If present, indicates the ID of the KMS key that was used for object encryption.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn sse_kms_key_id(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self.sse_kms_key_id = ::std::option::Option::Some(input.into());
self
}
/// <p>If present, indicates the ID of the KMS key that was used for object encryption.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn set_sse_kms_key_id(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self.sse_kms_key_id = input;
self
}
/// <p>If present, indicates the ID of the KMS key that was used for object encryption.</p>
/// <p>For multipart uploads, the completion response replaces the initiation value, including when absent.</p>
pub fn get_sse_kms_key_id(&self) -> &::std::option::Option<::std::string::String> {
&self.sse_kms_key_id
}
/// S3 request ID.
/// <p>Identifies the final request. A multipart upload reports its CompleteMultipartUpload request, and the initiation and part requests are not reported.</p>
#[allow(dead_code)]
pub(crate) fn request_id(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self._request_id = ::std::option::Option::Some(input.into());
self
}
/// S3 request ID.
/// <p>Identifies the final request. A multipart upload reports its CompleteMultipartUpload request, and the initiation and part requests are not reported.</p>
#[allow(dead_code)]
pub(crate) fn set_request_id(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self._request_id = input;
self
}
/// S3 request ID.
/// <p>Identifies the final request. A multipart upload reports its CompleteMultipartUpload request, and the initiation and part requests are not reported.</p>
#[allow(dead_code)]
pub(crate) fn get_request_id(&self) -> &::std::option::Option<::std::string::String> {
&self._request_id
}
/// S3 extended request ID.
/// <p>Identifies the final request. A multipart upload reports its CompleteMultipartUpload request, and the initiation and part requests are not reported.</p>
#[allow(dead_code)]
pub(crate) fn extended_request_id(
mut self,
input: impl ::std::convert::Into<::std::string::String>,
) -> Self {
self._extended_request_id = ::std::option::Option::Some(input.into());
self
}
/// S3 extended request ID.
/// <p>Identifies the final request. A multipart upload reports its CompleteMultipartUpload request, and the initiation and part requests are not reported.</p>
#[allow(dead_code)]
pub(crate) fn set_extended_request_id(
mut self,
input: ::std::option::Option<::std::string::String>,
) -> Self {
self._extended_request_id = input;
self
}
/// S3 extended request ID.
/// <p>Identifies the final request. A multipart upload reports its CompleteMultipartUpload request, and the initiation and part requests are not reported.</p>
#[allow(dead_code)]
pub(crate) fn get_extended_request_id(&self) -> &::std::option::Option<::std::string::String> {
&self._extended_request_id
}
/// Consumes the builder and constructs a [`UploadOutput`](crate::model::UploadOutput).
fn build_unchecked(self) -> crate::model::UploadOutput {
crate::model::UploadOutput {
abort_date: self.abort_date,
abort_rule_id: self.abort_rule_id,
bucket: self.bucket,
bucket_key_enabled: self.bucket_key_enabled,
checksum_algorithm: self.checksum_algorithm,
checksum_crc32: self.checksum_crc32,
checksum_crc32_c: self.checksum_crc32_c,
checksum_crc64_nvme: self.checksum_crc64_nvme,
checksum_md5: self.checksum_md5,
checksum_sha1: self.checksum_sha1,
checksum_sha256: self.checksum_sha256,
checksum_sha512: self.checksum_sha512,
checksum_type: self.checksum_type,
checksum_xxhash128: self.checksum_xxhash128,
checksum_xxhash3: self.checksum_xxhash3,
checksum_xxhash64: self.checksum_xxhash64,
e_tag: self.e_tag,
expiration: self.expiration,
key: self.key,
location: self.location,
request_charged: self.request_charged,
sse_customer_algorithm: self.sse_customer_algorithm,
sse_customer_key_md5: self.sse_customer_key_md5,
server_side_encryption: self.server_side_encryption,
size: self.size,
upload_id: self.upload_id,
version_id: self.version_id,
#[cfg(not(s3_tm_out_of_tree))]
metrics: self.metrics.expect("metrics must be set"),
sse_kms_encryption_context: self.sse_kms_encryption_context,
sse_kms_key_id: self.sse_kms_key_id,
_request_id: self._request_id,
_extended_request_id: self._extended_request_id,
}
}
}
impl ::std::fmt::Debug for UploadOutputBuilder {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
let mut formatter = f.debug_struct("UploadOutputBuilder");
formatter.field("abort_date", &self.abort_date);
formatter.field("abort_rule_id", &self.abort_rule_id);
formatter.field("bucket", &self.bucket);
formatter.field("bucket_key_enabled", &self.bucket_key_enabled);
formatter.field("checksum_algorithm", &self.checksum_algorithm);
formatter.field("checksum_crc32", &self.checksum_crc32);
formatter.field("checksum_crc32_c", &self.checksum_crc32_c);
formatter.field("checksum_crc64_nvme", &self.checksum_crc64_nvme);
formatter.field("checksum_md5", &self.checksum_md5);
formatter.field("checksum_sha1", &self.checksum_sha1);
formatter.field("checksum_sha256", &self.checksum_sha256);
formatter.field("checksum_sha512", &self.checksum_sha512);
formatter.field("checksum_type", &self.checksum_type);
formatter.field("checksum_xxhash128", &self.checksum_xxhash128);
formatter.field("checksum_xxhash3", &self.checksum_xxhash3);
formatter.field("checksum_xxhash64", &self.checksum_xxhash64);
formatter.field("e_tag", &self.e_tag);
formatter.field("expiration", &self.expiration);
formatter.field("key", &self.key);
formatter.field("location", &self.location);
formatter.field("request_charged", &self.request_charged);
formatter.field("sse_customer_algorithm", &self.sse_customer_algorithm);
formatter.field("sse_customer_key_md5", &self.sse_customer_key_md5);
formatter.field("server_side_encryption", &self.server_side_encryption);
formatter.field("size", &self.size);
formatter.field("upload_id", &self.upload_id);
formatter.field("version_id", &self.version_id);
formatter.field(
"sse_kms_encryption_context",
&"*** Sensitive Data Redacted ***",
);
formatter.field("sse_kms_key_id", &"*** Sensitive Data Redacted ***");
formatter.field("_request_id", &self._request_id);
formatter.field("_extended_request_id", &self._extended_request_id);
formatter.finish()
}
}
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
impl UploadOutputBuilder {
/// Consumes the builder, validating required fields.
pub fn build(
self,
) -> ::std::result::Result<
crate::model::UploadOutput,
::aws_smithy_types::error::operation::BuildError,
> {
#[cfg(not(s3_tm_out_of_tree))]
if self.metrics.is_none() {
return Err(
::aws_smithy_types::error::operation::BuildError::missing_field(
"metrics",
"A required field was not set",
),
);
}
Ok(self.build_unchecked())
}
}