aws_sdk_s3/client/put_bucket_versioning.rs
1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3    /// Constructs a fluent builder for the [`PutBucketVersioning`](crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder) operation.
4    ///
5    /// - The fluent builder is configurable:
6    ///   - [`bucket(impl Into<String>)`](crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder::bucket) / [`set_bucket(Option<String>)`](crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder::set_bucket):<br>required: **true**<br><p>The bucket name.</p><br>
7    ///   - [`content_md5(impl Into<String>)`](crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder::content_md5) / [`set_content_md5(Option<String>)`](crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder::set_content_md5):<br>required: **false**<br><p>>The Base64 encoded 128-bit <code>MD5</code> digest of the data. You must use this header as a message integrity check to verify that the request body was not corrupted in transit. For more information, see <a href="http://www.ietf.org/rfc/rfc1864.txt">RFC 1864</a>.</p> <p>For requests made using the Amazon Web Services Command Line Interface (CLI) or Amazon Web Services SDKs, this field is calculated automatically.</p><br>
8    ///   - [`checksum_algorithm(ChecksumAlgorithm)`](crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder::checksum_algorithm) / [`set_checksum_algorithm(Option<ChecksumAlgorithm>)`](crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder::set_checksum_algorithm):<br>required: **false**<br><p>Indicates the algorithm used to create the checksum for the request when you use the SDK. This header will not provide any additional functionality if you don't use the SDK. When you send this header, there must be a corresponding <code>x-amz-checksum</code> or <code>x-amz-trailer</code> header sent. Otherwise, Amazon S3 fails the request with the HTTP status code <code>400 Bad Request</code>. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p> <p>If you provide an individual checksum, Amazon S3 ignores any provided <code>ChecksumAlgorithm</code> parameter.</p><br>
9    ///   - [`mfa(impl Into<String>)`](crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder::mfa) / [`set_mfa(Option<String>)`](crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder::set_mfa):<br>required: **false**<br><p>The concatenation of the authentication device's serial number, a space, and the value that is displayed on your authentication device. The serial number is the number that uniquely identifies the MFA device. For physical MFA devices, this is the unique serial number that's provided with the device. For virtual MFA devices, the serial number is the device ARN. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/manage-versioning-examples.html">Enabling versioning on buckets</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/MultiFactorAuthenticationDelete.html">Configuring MFA delete</a> in the <i>Amazon Simple Storage Service User Guide</i>.</p><br>
10    ///   - [`versioning_configuration(VersioningConfiguration)`](crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder::versioning_configuration) / [`set_versioning_configuration(Option<VersioningConfiguration>)`](crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder::set_versioning_configuration):<br>required: **true**<br><p>Container for setting the versioning state.</p><br>
11    ///   - [`expected_bucket_owner(impl Into<String>)`](crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder::expected_bucket_owner) / [`set_expected_bucket_owner(Option<String>)`](crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder::set_expected_bucket_owner):<br>required: **false**<br><p>The account ID of the expected bucket owner. If the account ID that you provide does not match the actual owner of the bucket, the request fails with the HTTP status code <code>403 Forbidden</code> (access denied).</p><br>
12    /// - On success, responds with [`PutBucketVersioningOutput`](crate::operation::put_bucket_versioning::PutBucketVersioningOutput)
13    /// - On failure, responds with [`SdkError<PutBucketVersioningError>`](crate::operation::put_bucket_versioning::PutBucketVersioningError)
14    pub fn put_bucket_versioning(&self) -> crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder {
15        crate::operation::put_bucket_versioning::builders::PutBucketVersioningFluentBuilder::new(self.handle.clone())
16    }
17}