aws_sdk_s3/operation/get_object/
builders.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2pub use crate::operation::get_object::_get_object_output::GetObjectOutputBuilder;
3
4pub use crate::operation::get_object::_get_object_input::GetObjectInputBuilder;
5
6impl GetObjectInputBuilder {
7    /// Sends a request with this input using the given client.
8    pub async fn send_with(
9        self,
10        client: &crate::Client,
11    ) -> ::std::result::Result<
12        crate::operation::get_object::GetObjectOutput,
13        ::aws_smithy_runtime_api::client::result::SdkError<
14            crate::operation::get_object::GetObjectError,
15            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
16        >,
17    > {
18        let mut fluent_builder = client.get_object();
19        fluent_builder.inner = self;
20        fluent_builder.send().await
21    }
22}
23/// Fluent builder constructing a request to `GetObject`.
24///
25/// <p>Retrieves an object from Amazon S3.</p>
26/// <p>In the <code>GetObject</code> request, specify the full key name for the object.</p>
27/// <p><b>General purpose buckets</b> - Both the virtual-hosted-style requests and the path-style requests are supported. For a virtual hosted-style request example, if you have the object <code>photos/2006/February/sample.jpg</code>, specify the object key name as <code>/photos/2006/February/sample.jpg</code>. For a path-style request example, if you have the object <code>photos/2006/February/sample.jpg</code> in the bucket named <code>examplebucket</code>, specify the object key name as <code>/examplebucket/photos/2006/February/sample.jpg</code>. For more information about request types, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/VirtualHosting.html#VirtualHostingSpecifyBucket">HTTP Host Header Bucket Specification</a> in the <i>Amazon S3 User Guide</i>.</p>
28/// <p><b>Directory buckets</b> - Only virtual-hosted-style requests are supported. For a virtual hosted-style request example, if you have the object <code>photos/2006/February/sample.jpg</code> in the bucket named <code>examplebucket--use1-az5--x-s3</code>, specify the object key name as <code>/photos/2006/February/sample.jpg</code>. Also, when you make requests to this API operation, your requests are sent to the Zonal endpoint. These endpoints support virtual-hosted-style requests in the format <code>https://<i>bucket_name</i>.s3express-<i>az_id</i>.<i>region</i>.amazonaws.com/<i>key-name</i> </code>. Path-style requests are not supported. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-Regions-and-Zones.html">Regional and Zonal endpoints</a> in the <i>Amazon S3 User Guide</i>.</p>
29/// <dl>
30/// <dt>
31/// Permissions
32/// </dt>
33/// <dd>
34/// <ul>
35/// <li>
36/// <p><b>General purpose bucket permissions</b> - You must have the required permissions in a policy. To use <code>GetObject</code>, you must have the <code>READ</code> access to the object (or version). If you grant <code>READ</code> access to the anonymous user, the <code>GetObject</code> operation returns the object without using an authorization header. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/using-with-s3-actions.html">Specifying permissions in a policy</a> in the <i>Amazon S3 User Guide</i>.</p>
37/// <p>If you include a <code>versionId</code> in your request header, you must have the <code>s3:GetObjectVersion</code> permission to access a specific version of an object. The <code>s3:GetObject</code> permission is not required in this scenario.</p>
38/// <p>If you request the current version of an object without a specific <code>versionId</code> in the request header, only the <code>s3:GetObject</code> permission is required. The <code>s3:GetObjectVersion</code> permission is not required in this scenario.</p>
39/// <p>If the object that you request doesn’t exist, the error that Amazon S3 returns depends on whether you also have the <code>s3:ListBucket</code> permission.</p>
40/// <ul>
41/// <li>
42/// <p>If you have the <code>s3:ListBucket</code> permission on the bucket, Amazon S3 returns an HTTP status code <code>404 Not Found</code> error.</p></li>
43/// <li>
44/// <p>If you don’t have the <code>s3:ListBucket</code> permission, Amazon S3 returns an HTTP status code <code>403 Access Denied</code> error.</p></li>
45/// </ul></li>
46/// <li>
47/// <p><b>Directory bucket permissions</b> - To grant access to this API operation on a directory bucket, we recommend that you use the <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html"> <code>CreateSession</code> </a> API operation for session-based authorization. Specifically, you grant the <code>s3express:CreateSession</code> permission to the directory bucket in a bucket policy or an IAM identity-based policy. Then, you make the <code>CreateSession</code> API call on the bucket to obtain a session token. With the session token in your request header, you can make API requests to this operation. After the session token expires, you make another <code>CreateSession</code> API call to generate a new session token for use. Amazon Web Services CLI or SDKs create session and refresh the session token automatically to avoid service interruptions when a session expires. For more information about authorization, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateSession.html"> <code>CreateSession</code> </a>.</p></li>
48/// </ul>
49/// </dd>
50/// <dt>
51/// Storage classes
52/// </dt>
53/// <dd>
54/// <p>If the object you are retrieving is stored in the S3 Glacier Flexible Retrieval storage class, the S3 Glacier Deep Archive storage class, the S3 Intelligent-Tiering Archive Access tier, or the S3 Intelligent-Tiering Deep Archive Access tier, before you can retrieve the object you must first restore a copy using <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_RestoreObject.html">RestoreObject</a>. Otherwise, this operation returns an <code>InvalidObjectState</code> error. For information about restoring archived objects, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/restoring-objects.html">Restoring Archived Objects</a> in the <i>Amazon S3 User Guide</i>.</p>
55/// <p><b>Directory buckets </b> - For directory buckets, only the S3 Express One Zone storage class is supported to store newly created objects. Unsupported storage class values won't write a destination object and will respond with the HTTP status code <code>400 Bad Request</code>.</p>
56/// </dd>
57/// <dt>
58/// Encryption
59/// </dt>
60/// <dd>
61/// <p>Encryption request headers, like <code>x-amz-server-side-encryption</code>, should not be sent for the <code>GetObject</code> requests, if your object uses server-side encryption with Amazon S3 managed encryption keys (SSE-S3), server-side encryption with Key Management Service (KMS) keys (SSE-KMS), or dual-layer server-side encryption with Amazon Web Services KMS keys (DSSE-KMS). If you include the header in your <code>GetObject</code> requests for the object that uses these types of keys, you’ll get an HTTP <code>400 Bad Request</code> error.</p>
62/// </dd>
63/// <dt>
64/// Overriding response header values through the request
65/// </dt>
66/// <dd>
67/// <p>There are times when you want to override certain response header values of a <code>GetObject</code> response. For example, you might override the <code>Content-Disposition</code> response header value through your <code>GetObject</code> request.</p>
68/// <p>You can override values for a set of response headers. These modified response header values are included only in a successful response, that is, when the HTTP status code <code>200 OK</code> is returned. The headers you can override using the following query parameters in the request are a subset of the headers that Amazon S3 accepts when you create an object.</p>
69/// <p>The response headers that you can override for the <code>GetObject</code> response are <code>Cache-Control</code>, <code>Content-Disposition</code>, <code>Content-Encoding</code>, <code>Content-Language</code>, <code>Content-Type</code>, and <code>Expires</code>.</p>
70/// <p>To override values for a set of response headers in the <code>GetObject</code> response, you can use the following query parameters in the request.</p>
71/// <ul>
72/// <li>
73/// <p><code>response-cache-control</code></p></li>
74/// <li>
75/// <p><code>response-content-disposition</code></p></li>
76/// <li>
77/// <p><code>response-content-encoding</code></p></li>
78/// <li>
79/// <p><code>response-content-language</code></p></li>
80/// <li>
81/// <p><code>response-content-type</code></p></li>
82/// <li>
83/// <p><code>response-expires</code></p></li>
84/// </ul><note>
85/// <p>When you use these parameters, you must sign the request by using either an Authorization header or a presigned URL. These parameters cannot be used with an unsigned (anonymous) request.</p>
86/// </note>
87/// </dd>
88/// <dt>
89/// HTTP Host header syntax
90/// </dt>
91/// <dd>
92/// <p><b>Directory buckets </b> - The HTTP Host header syntax is <code> <i>Bucket_name</i>.s3express-<i>az_id</i>.<i>region</i>.amazonaws.com</code>.</p>
93/// </dd>
94/// </dl>
95/// <p>The following operations are related to <code>GetObject</code>:</p>
96/// <ul>
97/// <li>
98/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_ListBuckets.html">ListBuckets</a></p></li>
99/// <li>
100/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAcl.html">GetObjectAcl</a></p></li>
101/// </ul>
102#[derive(::std::clone::Clone, ::std::fmt::Debug)]
103pub struct GetObjectFluentBuilder {
104    handle: ::std::sync::Arc<crate::client::Handle>,
105    inner: crate::operation::get_object::builders::GetObjectInputBuilder,
106    config_override: ::std::option::Option<crate::config::Builder>,
107}
108impl crate::client::customize::internal::CustomizableSend<crate::operation::get_object::GetObjectOutput, crate::operation::get_object::GetObjectError>
109    for GetObjectFluentBuilder
110{
111    fn send(
112        self,
113        config_override: crate::config::Builder,
114    ) -> crate::client::customize::internal::BoxFuture<
115        crate::client::customize::internal::SendResult<crate::operation::get_object::GetObjectOutput, crate::operation::get_object::GetObjectError>,
116    > {
117        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
118    }
119}
120impl GetObjectFluentBuilder {
121    /// Creates a new `GetObject`.
122    pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
123        Self {
124            handle,
125            inner: ::std::default::Default::default(),
126            config_override: ::std::option::Option::None,
127        }
128    }
129    /// Access the GetObject as a reference.
130    pub fn as_input(&self) -> &crate::operation::get_object::builders::GetObjectInputBuilder {
131        &self.inner
132    }
133    /// Sends the request and returns the response.
134    ///
135    /// If an error occurs, an `SdkError` will be returned with additional details that
136    /// can be matched against.
137    ///
138    /// By default, any retryable failures will be retried twice. Retry behavior
139    /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
140    /// set when configuring the client.
141    pub async fn send(
142        self,
143    ) -> ::std::result::Result<
144        crate::operation::get_object::GetObjectOutput,
145        ::aws_smithy_runtime_api::client::result::SdkError<
146            crate::operation::get_object::GetObjectError,
147            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
148        >,
149    > {
150        let input = self
151            .inner
152            .build()
153            .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
154        let runtime_plugins = crate::operation::get_object::GetObject::operation_runtime_plugins(
155            self.handle.runtime_plugins.clone(),
156            &self.handle.conf,
157            self.config_override,
158        );
159        crate::operation::get_object::GetObject::orchestrate(&runtime_plugins, input).await
160    }
161
162    /// Consumes this builder, creating a customizable operation that can be modified before being sent.
163    pub fn customize(
164        self,
165    ) -> crate::client::customize::CustomizableOperation<
166        crate::operation::get_object::GetObjectOutput,
167        crate::operation::get_object::GetObjectError,
168        Self,
169    > {
170        crate::client::customize::CustomizableOperation::new(self)
171    }
172    pub(crate) fn config_override(mut self, config_override: impl Into<crate::config::Builder>) -> Self {
173        self.set_config_override(Some(config_override.into()));
174        self
175    }
176
177    pub(crate) fn set_config_override(&mut self, config_override: Option<crate::config::Builder>) -> &mut Self {
178        self.config_override = config_override;
179        self
180    }
181    ///
182    /// Creates a presigned request for this operation.
183    ///
184    /// The `presigning_config` provides additional presigning-specific config values, such as the
185    /// amount of time the request should be valid for after creation.
186    ///
187    /// Presigned requests can be given to other users or applications to access a resource or perform
188    /// an operation without having access to the AWS security credentials.
189    ///
190    /// _Important:_ If you're using credentials that can expire, such as those from STS AssumeRole or SSO, then
191    /// the presigned request can only be valid for as long as the credentials used to create it are.
192    ///
193    #[allow(unused_mut)]
194    pub async fn presigned(
195        mut self,
196        presigning_config: crate::presigning::PresigningConfig,
197    ) -> ::std::result::Result<
198        crate::presigning::PresignedRequest,
199        ::aws_smithy_runtime_api::client::result::SdkError<
200            crate::operation::get_object::GetObjectError,
201            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
202        >,
203    > {
204        let runtime_plugins = crate::operation::get_object::GetObject::operation_runtime_plugins(
205            self.handle.runtime_plugins.clone(),
206            &self.handle.conf,
207            self.config_override,
208        )
209        .with_client_plugin(crate::presigning_interceptors::SigV4PresigningRuntimePlugin::new(
210            presigning_config,
211            ::aws_sigv4::http_request::SignableBody::UnsignedPayload,
212        ));
213
214        let input = self
215            .inner
216            .build()
217            .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
218        let mut context = crate::operation::get_object::GetObject::orchestrate_with_stop_point(
219            &runtime_plugins,
220            input,
221            ::aws_smithy_runtime::client::orchestrator::StopPoint::BeforeTransmit,
222        )
223        .await
224        .map_err(|err| {
225            err.map_service_error(|err| {
226                err.downcast::<crate::operation::get_object::GetObjectError>()
227                    .expect("correct error type")
228            })
229        })?;
230        let request = context.take_request().expect("request set before transmit");
231        crate::presigning::PresignedRequest::new(request).map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)
232    }
233    /// <p>The bucket name containing the object.</p>
234    /// <p><b>Directory buckets</b> - When you use this operation with a directory bucket, you must use virtual-hosted-style requests in the format <code> <i>Bucket_name</i>.s3express-<i>az_id</i>.<i>region</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Availability Zone. Bucket names must follow the format <code> <i>bucket_base_name</i>--<i>az-id</i>--x-s3</code> (for example, <code> <i>DOC-EXAMPLE-BUCKET</i>--<i>usw2-az1</i>--x-s3</code>). For information about bucket naming restrictions, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-bucket-naming-rules.html">Directory bucket naming rules</a> in the <i>Amazon S3 User Guide</i>.</p>
235    /// <p><b>Access points</b> - When you use this action with an access point, you must provide the alias of the access point in place of the bucket name or specify the access point ARN. When using the access point ARN, you must direct requests to the access point hostname. The access point hostname takes the form <i>AccessPointName</i>-<i>AccountId</i>.s3-accesspoint.<i>Region</i>.amazonaws.com. When using this action with an access point through the Amazon Web Services SDKs, you provide the access point ARN in place of the bucket name. For more information about access point ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-access-points.html">Using access points</a> in the <i>Amazon S3 User Guide</i>.</p>
236    /// <p><b>Object Lambda access points</b> - When you use this action with an Object Lambda access point, you must direct requests to the Object Lambda access point hostname. The Object Lambda access point hostname takes the form <i>AccessPointName</i>-<i>AccountId</i>.s3-object-lambda.<i>Region</i>.amazonaws.com.</p><note>
237    /// <p>Access points and Object Lambda access points are not supported by directory buckets.</p>
238    /// </note>
239    /// <p><b>S3 on Outposts</b> - When you use this action with Amazon S3 on Outposts, you must direct requests to the S3 on Outposts hostname. The S3 on Outposts hostname takes the form <code> <i>AccessPointName</i>-<i>AccountId</i>.<i>outpostID</i>.s3-outposts.<i>Region</i>.amazonaws.com</code>. When you use this action with S3 on Outposts through the Amazon Web Services SDKs, you provide the Outposts access point ARN in place of the bucket name. For more information about S3 on Outposts ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/S3onOutposts.html">What is S3 on Outposts?</a> in the <i>Amazon S3 User Guide</i>.</p>
240    pub fn bucket(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
241        self.inner = self.inner.bucket(input.into());
242        self
243    }
244    /// <p>The bucket name containing the object.</p>
245    /// <p><b>Directory buckets</b> - When you use this operation with a directory bucket, you must use virtual-hosted-style requests in the format <code> <i>Bucket_name</i>.s3express-<i>az_id</i>.<i>region</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Availability Zone. Bucket names must follow the format <code> <i>bucket_base_name</i>--<i>az-id</i>--x-s3</code> (for example, <code> <i>DOC-EXAMPLE-BUCKET</i>--<i>usw2-az1</i>--x-s3</code>). For information about bucket naming restrictions, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-bucket-naming-rules.html">Directory bucket naming rules</a> in the <i>Amazon S3 User Guide</i>.</p>
246    /// <p><b>Access points</b> - When you use this action with an access point, you must provide the alias of the access point in place of the bucket name or specify the access point ARN. When using the access point ARN, you must direct requests to the access point hostname. The access point hostname takes the form <i>AccessPointName</i>-<i>AccountId</i>.s3-accesspoint.<i>Region</i>.amazonaws.com. When using this action with an access point through the Amazon Web Services SDKs, you provide the access point ARN in place of the bucket name. For more information about access point ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-access-points.html">Using access points</a> in the <i>Amazon S3 User Guide</i>.</p>
247    /// <p><b>Object Lambda access points</b> - When you use this action with an Object Lambda access point, you must direct requests to the Object Lambda access point hostname. The Object Lambda access point hostname takes the form <i>AccessPointName</i>-<i>AccountId</i>.s3-object-lambda.<i>Region</i>.amazonaws.com.</p><note>
248    /// <p>Access points and Object Lambda access points are not supported by directory buckets.</p>
249    /// </note>
250    /// <p><b>S3 on Outposts</b> - When you use this action with Amazon S3 on Outposts, you must direct requests to the S3 on Outposts hostname. The S3 on Outposts hostname takes the form <code> <i>AccessPointName</i>-<i>AccountId</i>.<i>outpostID</i>.s3-outposts.<i>Region</i>.amazonaws.com</code>. When you use this action with S3 on Outposts through the Amazon Web Services SDKs, you provide the Outposts access point ARN in place of the bucket name. For more information about S3 on Outposts ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/S3onOutposts.html">What is S3 on Outposts?</a> in the <i>Amazon S3 User Guide</i>.</p>
251    pub fn set_bucket(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
252        self.inner = self.inner.set_bucket(input);
253        self
254    }
255    /// <p>The bucket name containing the object.</p>
256    /// <p><b>Directory buckets</b> - When you use this operation with a directory bucket, you must use virtual-hosted-style requests in the format <code> <i>Bucket_name</i>.s3express-<i>az_id</i>.<i>region</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Availability Zone. Bucket names must follow the format <code> <i>bucket_base_name</i>--<i>az-id</i>--x-s3</code> (for example, <code> <i>DOC-EXAMPLE-BUCKET</i>--<i>usw2-az1</i>--x-s3</code>). For information about bucket naming restrictions, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-bucket-naming-rules.html">Directory bucket naming rules</a> in the <i>Amazon S3 User Guide</i>.</p>
257    /// <p><b>Access points</b> - When you use this action with an access point, you must provide the alias of the access point in place of the bucket name or specify the access point ARN. When using the access point ARN, you must direct requests to the access point hostname. The access point hostname takes the form <i>AccessPointName</i>-<i>AccountId</i>.s3-accesspoint.<i>Region</i>.amazonaws.com. When using this action with an access point through the Amazon Web Services SDKs, you provide the access point ARN in place of the bucket name. For more information about access point ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-access-points.html">Using access points</a> in the <i>Amazon S3 User Guide</i>.</p>
258    /// <p><b>Object Lambda access points</b> - When you use this action with an Object Lambda access point, you must direct requests to the Object Lambda access point hostname. The Object Lambda access point hostname takes the form <i>AccessPointName</i>-<i>AccountId</i>.s3-object-lambda.<i>Region</i>.amazonaws.com.</p><note>
259    /// <p>Access points and Object Lambda access points are not supported by directory buckets.</p>
260    /// </note>
261    /// <p><b>S3 on Outposts</b> - When you use this action with Amazon S3 on Outposts, you must direct requests to the S3 on Outposts hostname. The S3 on Outposts hostname takes the form <code> <i>AccessPointName</i>-<i>AccountId</i>.<i>outpostID</i>.s3-outposts.<i>Region</i>.amazonaws.com</code>. When you use this action with S3 on Outposts through the Amazon Web Services SDKs, you provide the Outposts access point ARN in place of the bucket name. For more information about S3 on Outposts ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/S3onOutposts.html">What is S3 on Outposts?</a> in the <i>Amazon S3 User Guide</i>.</p>
262    pub fn get_bucket(&self) -> &::std::option::Option<::std::string::String> {
263        self.inner.get_bucket()
264    }
265    /// <p>Return the object only if its entity tag (ETag) is the same as the one specified in this header; otherwise, return a <code>412 Precondition Failed</code> error.</p>
266    /// <p>If both of the <code>If-Match</code> and <code>If-Unmodified-Since</code> headers are present in the request as follows: <code>If-Match</code> condition evaluates to <code>true</code>, and; <code>If-Unmodified-Since</code> condition evaluates to <code>false</code>; then, S3 returns <code>200 OK</code> and the data requested.</p>
267    /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p>
268    pub fn if_match(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
269        self.inner = self.inner.if_match(input.into());
270        self
271    }
272    /// <p>Return the object only if its entity tag (ETag) is the same as the one specified in this header; otherwise, return a <code>412 Precondition Failed</code> error.</p>
273    /// <p>If both of the <code>If-Match</code> and <code>If-Unmodified-Since</code> headers are present in the request as follows: <code>If-Match</code> condition evaluates to <code>true</code>, and; <code>If-Unmodified-Since</code> condition evaluates to <code>false</code>; then, S3 returns <code>200 OK</code> and the data requested.</p>
274    /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p>
275    pub fn set_if_match(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
276        self.inner = self.inner.set_if_match(input);
277        self
278    }
279    /// <p>Return the object only if its entity tag (ETag) is the same as the one specified in this header; otherwise, return a <code>412 Precondition Failed</code> error.</p>
280    /// <p>If both of the <code>If-Match</code> and <code>If-Unmodified-Since</code> headers are present in the request as follows: <code>If-Match</code> condition evaluates to <code>true</code>, and; <code>If-Unmodified-Since</code> condition evaluates to <code>false</code>; then, S3 returns <code>200 OK</code> and the data requested.</p>
281    /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p>
282    pub fn get_if_match(&self) -> &::std::option::Option<::std::string::String> {
283        self.inner.get_if_match()
284    }
285    /// <p>Return the object only if it has been modified since the specified time; otherwise, return a <code>304 Not Modified</code> error.</p>
286    /// <p>If both of the <code>If-None-Match</code> and <code>If-Modified-Since</code> headers are present in the request as follows:<code> If-None-Match</code> condition evaluates to <code>false</code>, and; <code>If-Modified-Since</code> condition evaluates to <code>true</code>; then, S3 returns <code>304 Not Modified</code> status code.</p>
287    /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p>
288    pub fn if_modified_since(mut self, input: ::aws_smithy_types::DateTime) -> Self {
289        self.inner = self.inner.if_modified_since(input);
290        self
291    }
292    /// <p>Return the object only if it has been modified since the specified time; otherwise, return a <code>304 Not Modified</code> error.</p>
293    /// <p>If both of the <code>If-None-Match</code> and <code>If-Modified-Since</code> headers are present in the request as follows:<code> If-None-Match</code> condition evaluates to <code>false</code>, and; <code>If-Modified-Since</code> condition evaluates to <code>true</code>; then, S3 returns <code>304 Not Modified</code> status code.</p>
294    /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p>
295    pub fn set_if_modified_since(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
296        self.inner = self.inner.set_if_modified_since(input);
297        self
298    }
299    /// <p>Return the object only if it has been modified since the specified time; otherwise, return a <code>304 Not Modified</code> error.</p>
300    /// <p>If both of the <code>If-None-Match</code> and <code>If-Modified-Since</code> headers are present in the request as follows:<code> If-None-Match</code> condition evaluates to <code>false</code>, and; <code>If-Modified-Since</code> condition evaluates to <code>true</code>; then, S3 returns <code>304 Not Modified</code> status code.</p>
301    /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p>
302    pub fn get_if_modified_since(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
303        self.inner.get_if_modified_since()
304    }
305    /// <p>Return the object only if its entity tag (ETag) is different from the one specified in this header; otherwise, return a <code>304 Not Modified</code> error.</p>
306    /// <p>If both of the <code>If-None-Match</code> and <code>If-Modified-Since</code> headers are present in the request as follows:<code> If-None-Match</code> condition evaluates to <code>false</code>, and; <code>If-Modified-Since</code> condition evaluates to <code>true</code>; then, S3 returns <code>304 Not Modified</code> HTTP status code.</p>
307    /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p>
308    pub fn if_none_match(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
309        self.inner = self.inner.if_none_match(input.into());
310        self
311    }
312    /// <p>Return the object only if its entity tag (ETag) is different from the one specified in this header; otherwise, return a <code>304 Not Modified</code> error.</p>
313    /// <p>If both of the <code>If-None-Match</code> and <code>If-Modified-Since</code> headers are present in the request as follows:<code> If-None-Match</code> condition evaluates to <code>false</code>, and; <code>If-Modified-Since</code> condition evaluates to <code>true</code>; then, S3 returns <code>304 Not Modified</code> HTTP status code.</p>
314    /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p>
315    pub fn set_if_none_match(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
316        self.inner = self.inner.set_if_none_match(input);
317        self
318    }
319    /// <p>Return the object only if its entity tag (ETag) is different from the one specified in this header; otherwise, return a <code>304 Not Modified</code> error.</p>
320    /// <p>If both of the <code>If-None-Match</code> and <code>If-Modified-Since</code> headers are present in the request as follows:<code> If-None-Match</code> condition evaluates to <code>false</code>, and; <code>If-Modified-Since</code> condition evaluates to <code>true</code>; then, S3 returns <code>304 Not Modified</code> HTTP status code.</p>
321    /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p>
322    pub fn get_if_none_match(&self) -> &::std::option::Option<::std::string::String> {
323        self.inner.get_if_none_match()
324    }
325    /// <p>Return the object only if it has not been modified since the specified time; otherwise, return a <code>412 Precondition Failed</code> error.</p>
326    /// <p>If both of the <code>If-Match</code> and <code>If-Unmodified-Since</code> headers are present in the request as follows: <code>If-Match</code> condition evaluates to <code>true</code>, and; <code>If-Unmodified-Since</code> condition evaluates to <code>false</code>; then, S3 returns <code>200 OK</code> and the data requested.</p>
327    /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p>
328    pub fn if_unmodified_since(mut self, input: ::aws_smithy_types::DateTime) -> Self {
329        self.inner = self.inner.if_unmodified_since(input);
330        self
331    }
332    /// <p>Return the object only if it has not been modified since the specified time; otherwise, return a <code>412 Precondition Failed</code> error.</p>
333    /// <p>If both of the <code>If-Match</code> and <code>If-Unmodified-Since</code> headers are present in the request as follows: <code>If-Match</code> condition evaluates to <code>true</code>, and; <code>If-Unmodified-Since</code> condition evaluates to <code>false</code>; then, S3 returns <code>200 OK</code> and the data requested.</p>
334    /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p>
335    pub fn set_if_unmodified_since(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
336        self.inner = self.inner.set_if_unmodified_since(input);
337        self
338    }
339    /// <p>Return the object only if it has not been modified since the specified time; otherwise, return a <code>412 Precondition Failed</code> error.</p>
340    /// <p>If both of the <code>If-Match</code> and <code>If-Unmodified-Since</code> headers are present in the request as follows: <code>If-Match</code> condition evaluates to <code>true</code>, and; <code>If-Unmodified-Since</code> condition evaluates to <code>false</code>; then, S3 returns <code>200 OK</code> and the data requested.</p>
341    /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>.</p>
342    pub fn get_if_unmodified_since(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
343        self.inner.get_if_unmodified_since()
344    }
345    /// <p>Key of the object to get.</p>
346    pub fn key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
347        self.inner = self.inner.key(input.into());
348        self
349    }
350    /// <p>Key of the object to get.</p>
351    pub fn set_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
352        self.inner = self.inner.set_key(input);
353        self
354    }
355    /// <p>Key of the object to get.</p>
356    pub fn get_key(&self) -> &::std::option::Option<::std::string::String> {
357        self.inner.get_key()
358    }
359    /// <p>Downloads the specified byte range of an object. For more information about the HTTP Range header, see <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-range">https://www.rfc-editor.org/rfc/rfc9110.html#name-range</a>.</p><note>
360    /// <p>Amazon S3 doesn't support retrieving multiple ranges of data per <code>GET</code> request.</p>
361    /// </note>
362    pub fn range(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
363        self.inner = self.inner.range(input.into());
364        self
365    }
366    /// <p>Downloads the specified byte range of an object. For more information about the HTTP Range header, see <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-range">https://www.rfc-editor.org/rfc/rfc9110.html#name-range</a>.</p><note>
367    /// <p>Amazon S3 doesn't support retrieving multiple ranges of data per <code>GET</code> request.</p>
368    /// </note>
369    pub fn set_range(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
370        self.inner = self.inner.set_range(input);
371        self
372    }
373    /// <p>Downloads the specified byte range of an object. For more information about the HTTP Range header, see <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-range">https://www.rfc-editor.org/rfc/rfc9110.html#name-range</a>.</p><note>
374    /// <p>Amazon S3 doesn't support retrieving multiple ranges of data per <code>GET</code> request.</p>
375    /// </note>
376    pub fn get_range(&self) -> &::std::option::Option<::std::string::String> {
377        self.inner.get_range()
378    }
379    /// <p>Sets the <code>Cache-Control</code> header of the response.</p>
380    pub fn response_cache_control(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
381        self.inner = self.inner.response_cache_control(input.into());
382        self
383    }
384    /// <p>Sets the <code>Cache-Control</code> header of the response.</p>
385    pub fn set_response_cache_control(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
386        self.inner = self.inner.set_response_cache_control(input);
387        self
388    }
389    /// <p>Sets the <code>Cache-Control</code> header of the response.</p>
390    pub fn get_response_cache_control(&self) -> &::std::option::Option<::std::string::String> {
391        self.inner.get_response_cache_control()
392    }
393    /// <p>Sets the <code>Content-Disposition</code> header of the response.</p>
394    pub fn response_content_disposition(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
395        self.inner = self.inner.response_content_disposition(input.into());
396        self
397    }
398    /// <p>Sets the <code>Content-Disposition</code> header of the response.</p>
399    pub fn set_response_content_disposition(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
400        self.inner = self.inner.set_response_content_disposition(input);
401        self
402    }
403    /// <p>Sets the <code>Content-Disposition</code> header of the response.</p>
404    pub fn get_response_content_disposition(&self) -> &::std::option::Option<::std::string::String> {
405        self.inner.get_response_content_disposition()
406    }
407    /// <p>Sets the <code>Content-Encoding</code> header of the response.</p>
408    pub fn response_content_encoding(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
409        self.inner = self.inner.response_content_encoding(input.into());
410        self
411    }
412    /// <p>Sets the <code>Content-Encoding</code> header of the response.</p>
413    pub fn set_response_content_encoding(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
414        self.inner = self.inner.set_response_content_encoding(input);
415        self
416    }
417    /// <p>Sets the <code>Content-Encoding</code> header of the response.</p>
418    pub fn get_response_content_encoding(&self) -> &::std::option::Option<::std::string::String> {
419        self.inner.get_response_content_encoding()
420    }
421    /// <p>Sets the <code>Content-Language</code> header of the response.</p>
422    pub fn response_content_language(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
423        self.inner = self.inner.response_content_language(input.into());
424        self
425    }
426    /// <p>Sets the <code>Content-Language</code> header of the response.</p>
427    pub fn set_response_content_language(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
428        self.inner = self.inner.set_response_content_language(input);
429        self
430    }
431    /// <p>Sets the <code>Content-Language</code> header of the response.</p>
432    pub fn get_response_content_language(&self) -> &::std::option::Option<::std::string::String> {
433        self.inner.get_response_content_language()
434    }
435    /// <p>Sets the <code>Content-Type</code> header of the response.</p>
436    pub fn response_content_type(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
437        self.inner = self.inner.response_content_type(input.into());
438        self
439    }
440    /// <p>Sets the <code>Content-Type</code> header of the response.</p>
441    pub fn set_response_content_type(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
442        self.inner = self.inner.set_response_content_type(input);
443        self
444    }
445    /// <p>Sets the <code>Content-Type</code> header of the response.</p>
446    pub fn get_response_content_type(&self) -> &::std::option::Option<::std::string::String> {
447        self.inner.get_response_content_type()
448    }
449    /// <p>Sets the <code>Expires</code> header of the response.</p>
450    pub fn response_expires(mut self, input: ::aws_smithy_types::DateTime) -> Self {
451        self.inner = self.inner.response_expires(input);
452        self
453    }
454    /// <p>Sets the <code>Expires</code> header of the response.</p>
455    pub fn set_response_expires(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
456        self.inner = self.inner.set_response_expires(input);
457        self
458    }
459    /// <p>Sets the <code>Expires</code> header of the response.</p>
460    pub fn get_response_expires(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
461        self.inner.get_response_expires()
462    }
463    /// <p>Version ID used to reference a specific version of the object.</p>
464    /// <p>By default, the <code>GetObject</code> operation returns the current version of an object. To return a different version, use the <code>versionId</code> subresource.</p><note>
465    /// <ul>
466    /// <li>
467    /// <p>If you include a <code>versionId</code> in your request header, you must have the <code>s3:GetObjectVersion</code> permission to access a specific version of an object. The <code>s3:GetObject</code> permission is not required in this scenario.</p></li>
468    /// <li>
469    /// <p>If you request the current version of an object without a specific <code>versionId</code> in the request header, only the <code>s3:GetObject</code> permission is required. The <code>s3:GetObjectVersion</code> permission is not required in this scenario.</p></li>
470    /// <li>
471    /// <p><b>Directory buckets</b> - S3 Versioning isn't enabled and supported for directory buckets. For this API operation, only the <code>null</code> value of the version ID is supported by directory buckets. You can only specify <code>null</code> to the <code>versionId</code> query parameter in the request.</p></li>
472    /// </ul>
473    /// </note>
474    /// <p>For more information about versioning, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketVersioning.html">PutBucketVersioning</a>.</p>
475    pub fn version_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
476        self.inner = self.inner.version_id(input.into());
477        self
478    }
479    /// <p>Version ID used to reference a specific version of the object.</p>
480    /// <p>By default, the <code>GetObject</code> operation returns the current version of an object. To return a different version, use the <code>versionId</code> subresource.</p><note>
481    /// <ul>
482    /// <li>
483    /// <p>If you include a <code>versionId</code> in your request header, you must have the <code>s3:GetObjectVersion</code> permission to access a specific version of an object. The <code>s3:GetObject</code> permission is not required in this scenario.</p></li>
484    /// <li>
485    /// <p>If you request the current version of an object without a specific <code>versionId</code> in the request header, only the <code>s3:GetObject</code> permission is required. The <code>s3:GetObjectVersion</code> permission is not required in this scenario.</p></li>
486    /// <li>
487    /// <p><b>Directory buckets</b> - S3 Versioning isn't enabled and supported for directory buckets. For this API operation, only the <code>null</code> value of the version ID is supported by directory buckets. You can only specify <code>null</code> to the <code>versionId</code> query parameter in the request.</p></li>
488    /// </ul>
489    /// </note>
490    /// <p>For more information about versioning, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketVersioning.html">PutBucketVersioning</a>.</p>
491    pub fn set_version_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
492        self.inner = self.inner.set_version_id(input);
493        self
494    }
495    /// <p>Version ID used to reference a specific version of the object.</p>
496    /// <p>By default, the <code>GetObject</code> operation returns the current version of an object. To return a different version, use the <code>versionId</code> subresource.</p><note>
497    /// <ul>
498    /// <li>
499    /// <p>If you include a <code>versionId</code> in your request header, you must have the <code>s3:GetObjectVersion</code> permission to access a specific version of an object. The <code>s3:GetObject</code> permission is not required in this scenario.</p></li>
500    /// <li>
501    /// <p>If you request the current version of an object without a specific <code>versionId</code> in the request header, only the <code>s3:GetObject</code> permission is required. The <code>s3:GetObjectVersion</code> permission is not required in this scenario.</p></li>
502    /// <li>
503    /// <p><b>Directory buckets</b> - S3 Versioning isn't enabled and supported for directory buckets. For this API operation, only the <code>null</code> value of the version ID is supported by directory buckets. You can only specify <code>null</code> to the <code>versionId</code> query parameter in the request.</p></li>
504    /// </ul>
505    /// </note>
506    /// <p>For more information about versioning, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketVersioning.html">PutBucketVersioning</a>.</p>
507    pub fn get_version_id(&self) -> &::std::option::Option<::std::string::String> {
508        self.inner.get_version_id()
509    }
510    /// <p>Specifies the algorithm to use when decrypting the object (for example, <code>AES256</code>).</p>
511    /// <p>If you encrypt an object by using server-side encryption with customer-provided encryption keys (SSE-C) when you store the object in Amazon S3, then when you GET the object, you must use the following headers:</p>
512    /// <ul>
513    /// <li>
514    /// <p><code>x-amz-server-side-encryption-customer-algorithm</code></p></li>
515    /// <li>
516    /// <p><code>x-amz-server-side-encryption-customer-key</code></p></li>
517    /// <li>
518    /// <p><code>x-amz-server-side-encryption-customer-key-MD5</code></p></li>
519    /// </ul>
520    /// <p>For more information about SSE-C, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html">Server-Side Encryption (Using Customer-Provided Encryption Keys)</a> in the <i>Amazon S3 User Guide</i>.</p><note>
521    /// <p>This functionality is not supported for directory buckets.</p>
522    /// </note>
523    pub fn sse_customer_algorithm(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
524        self.inner = self.inner.sse_customer_algorithm(input.into());
525        self
526    }
527    /// <p>Specifies the algorithm to use when decrypting the object (for example, <code>AES256</code>).</p>
528    /// <p>If you encrypt an object by using server-side encryption with customer-provided encryption keys (SSE-C) when you store the object in Amazon S3, then when you GET the object, you must use the following headers:</p>
529    /// <ul>
530    /// <li>
531    /// <p><code>x-amz-server-side-encryption-customer-algorithm</code></p></li>
532    /// <li>
533    /// <p><code>x-amz-server-side-encryption-customer-key</code></p></li>
534    /// <li>
535    /// <p><code>x-amz-server-side-encryption-customer-key-MD5</code></p></li>
536    /// </ul>
537    /// <p>For more information about SSE-C, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html">Server-Side Encryption (Using Customer-Provided Encryption Keys)</a> in the <i>Amazon S3 User Guide</i>.</p><note>
538    /// <p>This functionality is not supported for directory buckets.</p>
539    /// </note>
540    pub fn set_sse_customer_algorithm(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
541        self.inner = self.inner.set_sse_customer_algorithm(input);
542        self
543    }
544    /// <p>Specifies the algorithm to use when decrypting the object (for example, <code>AES256</code>).</p>
545    /// <p>If you encrypt an object by using server-side encryption with customer-provided encryption keys (SSE-C) when you store the object in Amazon S3, then when you GET the object, you must use the following headers:</p>
546    /// <ul>
547    /// <li>
548    /// <p><code>x-amz-server-side-encryption-customer-algorithm</code></p></li>
549    /// <li>
550    /// <p><code>x-amz-server-side-encryption-customer-key</code></p></li>
551    /// <li>
552    /// <p><code>x-amz-server-side-encryption-customer-key-MD5</code></p></li>
553    /// </ul>
554    /// <p>For more information about SSE-C, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html">Server-Side Encryption (Using Customer-Provided Encryption Keys)</a> in the <i>Amazon S3 User Guide</i>.</p><note>
555    /// <p>This functionality is not supported for directory buckets.</p>
556    /// </note>
557    pub fn get_sse_customer_algorithm(&self) -> &::std::option::Option<::std::string::String> {
558        self.inner.get_sse_customer_algorithm()
559    }
560    /// <p>Specifies the customer-provided encryption key that you originally provided for Amazon S3 to encrypt the data before storing it. This value is used to decrypt the object when recovering it and must match the one used when storing the data. The key must be appropriate for use with the algorithm specified in the <code>x-amz-server-side-encryption-customer-algorithm</code> header.</p>
561    /// <p>If you encrypt an object by using server-side encryption with customer-provided encryption keys (SSE-C) when you store the object in Amazon S3, then when you GET the object, you must use the following headers:</p>
562    /// <ul>
563    /// <li>
564    /// <p><code>x-amz-server-side-encryption-customer-algorithm</code></p></li>
565    /// <li>
566    /// <p><code>x-amz-server-side-encryption-customer-key</code></p></li>
567    /// <li>
568    /// <p><code>x-amz-server-side-encryption-customer-key-MD5</code></p></li>
569    /// </ul>
570    /// <p>For more information about SSE-C, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html">Server-Side Encryption (Using Customer-Provided Encryption Keys)</a> in the <i>Amazon S3 User Guide</i>.</p><note>
571    /// <p>This functionality is not supported for directory buckets.</p>
572    /// </note>
573    pub fn sse_customer_key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
574        self.inner = self.inner.sse_customer_key(input.into());
575        self
576    }
577    /// <p>Specifies the customer-provided encryption key that you originally provided for Amazon S3 to encrypt the data before storing it. This value is used to decrypt the object when recovering it and must match the one used when storing the data. The key must be appropriate for use with the algorithm specified in the <code>x-amz-server-side-encryption-customer-algorithm</code> header.</p>
578    /// <p>If you encrypt an object by using server-side encryption with customer-provided encryption keys (SSE-C) when you store the object in Amazon S3, then when you GET the object, you must use the following headers:</p>
579    /// <ul>
580    /// <li>
581    /// <p><code>x-amz-server-side-encryption-customer-algorithm</code></p></li>
582    /// <li>
583    /// <p><code>x-amz-server-side-encryption-customer-key</code></p></li>
584    /// <li>
585    /// <p><code>x-amz-server-side-encryption-customer-key-MD5</code></p></li>
586    /// </ul>
587    /// <p>For more information about SSE-C, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html">Server-Side Encryption (Using Customer-Provided Encryption Keys)</a> in the <i>Amazon S3 User Guide</i>.</p><note>
588    /// <p>This functionality is not supported for directory buckets.</p>
589    /// </note>
590    pub fn set_sse_customer_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
591        self.inner = self.inner.set_sse_customer_key(input);
592        self
593    }
594    /// <p>Specifies the customer-provided encryption key that you originally provided for Amazon S3 to encrypt the data before storing it. This value is used to decrypt the object when recovering it and must match the one used when storing the data. The key must be appropriate for use with the algorithm specified in the <code>x-amz-server-side-encryption-customer-algorithm</code> header.</p>
595    /// <p>If you encrypt an object by using server-side encryption with customer-provided encryption keys (SSE-C) when you store the object in Amazon S3, then when you GET the object, you must use the following headers:</p>
596    /// <ul>
597    /// <li>
598    /// <p><code>x-amz-server-side-encryption-customer-algorithm</code></p></li>
599    /// <li>
600    /// <p><code>x-amz-server-side-encryption-customer-key</code></p></li>
601    /// <li>
602    /// <p><code>x-amz-server-side-encryption-customer-key-MD5</code></p></li>
603    /// </ul>
604    /// <p>For more information about SSE-C, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html">Server-Side Encryption (Using Customer-Provided Encryption Keys)</a> in the <i>Amazon S3 User Guide</i>.</p><note>
605    /// <p>This functionality is not supported for directory buckets.</p>
606    /// </note>
607    pub fn get_sse_customer_key(&self) -> &::std::option::Option<::std::string::String> {
608        self.inner.get_sse_customer_key()
609    }
610    /// <p>Specifies the 128-bit MD5 digest of the customer-provided encryption key according to RFC 1321. Amazon S3 uses this header for a message integrity check to ensure that the encryption key was transmitted without error.</p>
611    /// <p>If you encrypt an object by using server-side encryption with customer-provided encryption keys (SSE-C) when you store the object in Amazon S3, then when you GET the object, you must use the following headers:</p>
612    /// <ul>
613    /// <li>
614    /// <p><code>x-amz-server-side-encryption-customer-algorithm</code></p></li>
615    /// <li>
616    /// <p><code>x-amz-server-side-encryption-customer-key</code></p></li>
617    /// <li>
618    /// <p><code>x-amz-server-side-encryption-customer-key-MD5</code></p></li>
619    /// </ul>
620    /// <p>For more information about SSE-C, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html">Server-Side Encryption (Using Customer-Provided Encryption Keys)</a> in the <i>Amazon S3 User Guide</i>.</p><note>
621    /// <p>This functionality is not supported for directory buckets.</p>
622    /// </note>
623    pub fn sse_customer_key_md5(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
624        self.inner = self.inner.sse_customer_key_md5(input.into());
625        self
626    }
627    /// <p>Specifies the 128-bit MD5 digest of the customer-provided encryption key according to RFC 1321. Amazon S3 uses this header for a message integrity check to ensure that the encryption key was transmitted without error.</p>
628    /// <p>If you encrypt an object by using server-side encryption with customer-provided encryption keys (SSE-C) when you store the object in Amazon S3, then when you GET the object, you must use the following headers:</p>
629    /// <ul>
630    /// <li>
631    /// <p><code>x-amz-server-side-encryption-customer-algorithm</code></p></li>
632    /// <li>
633    /// <p><code>x-amz-server-side-encryption-customer-key</code></p></li>
634    /// <li>
635    /// <p><code>x-amz-server-side-encryption-customer-key-MD5</code></p></li>
636    /// </ul>
637    /// <p>For more information about SSE-C, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html">Server-Side Encryption (Using Customer-Provided Encryption Keys)</a> in the <i>Amazon S3 User Guide</i>.</p><note>
638    /// <p>This functionality is not supported for directory buckets.</p>
639    /// </note>
640    pub fn set_sse_customer_key_md5(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
641        self.inner = self.inner.set_sse_customer_key_md5(input);
642        self
643    }
644    /// <p>Specifies the 128-bit MD5 digest of the customer-provided encryption key according to RFC 1321. Amazon S3 uses this header for a message integrity check to ensure that the encryption key was transmitted without error.</p>
645    /// <p>If you encrypt an object by using server-side encryption with customer-provided encryption keys (SSE-C) when you store the object in Amazon S3, then when you GET the object, you must use the following headers:</p>
646    /// <ul>
647    /// <li>
648    /// <p><code>x-amz-server-side-encryption-customer-algorithm</code></p></li>
649    /// <li>
650    /// <p><code>x-amz-server-side-encryption-customer-key</code></p></li>
651    /// <li>
652    /// <p><code>x-amz-server-side-encryption-customer-key-MD5</code></p></li>
653    /// </ul>
654    /// <p>For more information about SSE-C, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ServerSideEncryptionCustomerKeys.html">Server-Side Encryption (Using Customer-Provided Encryption Keys)</a> in the <i>Amazon S3 User Guide</i>.</p><note>
655    /// <p>This functionality is not supported for directory buckets.</p>
656    /// </note>
657    pub fn get_sse_customer_key_md5(&self) -> &::std::option::Option<::std::string::String> {
658        self.inner.get_sse_customer_key_md5()
659    }
660    /// <p>Confirms that the requester knows that they will be charged for the request. Bucket owners need not specify this parameter in their requests. If either the source or destination S3 bucket has Requester Pays enabled, the requester will pay for corresponding charges to copy the object. For information about downloading objects from Requester Pays buckets, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html">Downloading Objects in Requester Pays Buckets</a> in the <i>Amazon S3 User Guide</i>.</p><note>
661    /// <p>This functionality is not supported for directory buckets.</p>
662    /// </note>
663    pub fn request_payer(mut self, input: crate::types::RequestPayer) -> Self {
664        self.inner = self.inner.request_payer(input);
665        self
666    }
667    /// <p>Confirms that the requester knows that they will be charged for the request. Bucket owners need not specify this parameter in their requests. If either the source or destination S3 bucket has Requester Pays enabled, the requester will pay for corresponding charges to copy the object. For information about downloading objects from Requester Pays buckets, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html">Downloading Objects in Requester Pays Buckets</a> in the <i>Amazon S3 User Guide</i>.</p><note>
668    /// <p>This functionality is not supported for directory buckets.</p>
669    /// </note>
670    pub fn set_request_payer(mut self, input: ::std::option::Option<crate::types::RequestPayer>) -> Self {
671        self.inner = self.inner.set_request_payer(input);
672        self
673    }
674    /// <p>Confirms that the requester knows that they will be charged for the request. Bucket owners need not specify this parameter in their requests. If either the source or destination S3 bucket has Requester Pays enabled, the requester will pay for corresponding charges to copy the object. For information about downloading objects from Requester Pays buckets, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/ObjectsinRequesterPaysBuckets.html">Downloading Objects in Requester Pays Buckets</a> in the <i>Amazon S3 User Guide</i>.</p><note>
675    /// <p>This functionality is not supported for directory buckets.</p>
676    /// </note>
677    pub fn get_request_payer(&self) -> &::std::option::Option<crate::types::RequestPayer> {
678        self.inner.get_request_payer()
679    }
680    /// <p>Part number of the object being read. This is a positive integer between 1 and 10,000. Effectively performs a 'ranged' GET request for the part specified. Useful for downloading just a part of an object.</p>
681    pub fn part_number(mut self, input: i32) -> Self {
682        self.inner = self.inner.part_number(input);
683        self
684    }
685    /// <p>Part number of the object being read. This is a positive integer between 1 and 10,000. Effectively performs a 'ranged' GET request for the part specified. Useful for downloading just a part of an object.</p>
686    pub fn set_part_number(mut self, input: ::std::option::Option<i32>) -> Self {
687        self.inner = self.inner.set_part_number(input);
688        self
689    }
690    /// <p>Part number of the object being read. This is a positive integer between 1 and 10,000. Effectively performs a 'ranged' GET request for the part specified. Useful for downloading just a part of an object.</p>
691    pub fn get_part_number(&self) -> &::std::option::Option<i32> {
692        self.inner.get_part_number()
693    }
694    /// <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>
695    pub fn expected_bucket_owner(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
696        self.inner = self.inner.expected_bucket_owner(input.into());
697        self
698    }
699    /// <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>
700    pub fn set_expected_bucket_owner(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
701        self.inner = self.inner.set_expected_bucket_owner(input);
702        self
703    }
704    /// <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>
705    pub fn get_expected_bucket_owner(&self) -> &::std::option::Option<::std::string::String> {
706        self.inner.get_expected_bucket_owner()
707    }
708    /// <p>To retrieve the checksum, this mode must be enabled.</p>
709    pub fn checksum_mode(mut self, input: crate::types::ChecksumMode) -> Self {
710        self.inner = self.inner.checksum_mode(input);
711        self
712    }
713    /// <p>To retrieve the checksum, this mode must be enabled.</p>
714    pub fn set_checksum_mode(mut self, input: ::std::option::Option<crate::types::ChecksumMode>) -> Self {
715        self.inner = self.inner.set_checksum_mode(input);
716        self
717    }
718    /// <p>To retrieve the checksum, this mode must be enabled.</p>
719    pub fn get_checksum_mode(&self) -> &::std::option::Option<crate::types::ChecksumMode> {
720        self.inner.get_checksum_mode()
721    }
722}
723
724impl crate::client::customize::internal::CustomizablePresigned<crate::operation::get_object::GetObjectError> for GetObjectFluentBuilder {
725    fn presign(
726        self,
727        config_override: crate::config::Builder,
728        presigning_config: crate::presigning::PresigningConfig,
729    ) -> crate::client::customize::internal::BoxFuture<
730        crate::client::customize::internal::SendResult<crate::presigning::PresignedRequest, crate::operation::get_object::GetObjectError>,
731    > {
732        ::std::boxed::Box::pin(async move { self.config_override(config_override).presigned(presigning_config).await })
733    }
734}