aws_sdk_s3/operation/put_object/builders.rs
1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2pub use crate::operation::put_object::_put_object_input::PutObjectInputBuilder;
3
4pub use crate::operation::put_object::_put_object_output::PutObjectOutputBuilder;
5
6impl crate::operation::put_object::builders::PutObjectInputBuilder {
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::put_object::PutObjectOutput,
13 ::aws_smithy_runtime_api::client::result::SdkError<
14 crate::operation::put_object::PutObjectError,
15 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
16 >,
17 > {
18 let mut fluent_builder = client.put_object();
19 fluent_builder.inner = self;
20 fluent_builder.send().await
21 }
22}
23/// Fluent builder constructing a request to `PutObject`.
24///
25/// <important>
26/// <p>End of support notice: As of October 1, 2025, Amazon S3 has discontinued support for Email Grantee Access Control Lists (ACLs). If you attempt to use an Email Grantee ACL in a request after October 1, 2025, the request will receive an <code>HTTP 405</code> (Method Not Allowed) error.</p>
27/// <p>This change affects the following Amazon Web Services Regions: US East (N. Virginia), US West (N. California), US West (Oregon), Asia Pacific (Singapore), Asia Pacific (Sydney), Asia Pacific (Tokyo), Europe (Ireland), and South America (São Paulo).</p>
28/// </important>
29/// <p>Adds an object to a bucket.</p><note>
30/// <ul>
31/// <li>
32/// <p>Amazon S3 never adds partial objects; if you receive a success response, Amazon S3 added the entire object to the bucket. You cannot use <code>PutObject</code> to only update a single piece of metadata for an existing object. You must put the entire object with updated metadata if you want to update some values.</p></li>
33/// <li>
34/// <p>If your bucket uses the bucket owner enforced setting for Object Ownership, ACLs are disabled and no longer affect permissions. All objects written to the bucket by any account will be owned by the bucket owner.</p></li>
35/// <li>
36/// <p><b>Directory buckets</b> - For directory buckets, you must make requests for this API operation to the Zonal endpoint. These endpoints support virtual-hosted-style requests in the format <code>https://<i>amzn-s3-demo-bucket</i>.s3express-<i>zone-id</i>.<i>region-code</i>.amazonaws.com/<i>key-name</i> </code>. Path-style requests are not supported. For more information about endpoints in Availability Zones, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/endpoint-directory-buckets-AZ.html">Regional and Zonal endpoints for directory buckets in Availability Zones</a> in the <i>Amazon S3 User Guide</i>. For more information about endpoints in Local Zones, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-lzs-for-directory-buckets.html">Concepts for directory buckets in Local Zones</a> in the <i>Amazon S3 User Guide</i>.</p></li>
37/// </ul>
38/// </note>
39/// <p>Amazon S3 is a distributed system. If it receives multiple write requests for the same object simultaneously, it overwrites all but the last object written. However, Amazon S3 provides features that can modify this behavior:</p>
40/// <ul>
41/// <li>
42/// <p><b>S3 Object Lock</b> - To prevent objects from being deleted or overwritten, you can use <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lock.html">Amazon S3 Object Lock</a> in the <i>Amazon S3 User Guide</i>.</p><note>
43/// <p>This functionality is not supported for directory buckets.</p>
44/// </note></li>
45/// <li>
46/// <p><b>If-None-Match</b> - Uploads the object only if the object key name does not already exist in the specified bucket. Otherwise, Amazon S3 returns a <code>412 Precondition Failed</code> error. If a conflicting operation occurs during the upload, S3 returns a <code>409 ConditionalRequestConflict</code> response. On a 409 failure, retry the upload.</p>
47/// <p>Expects the * character (asterisk).</p>
48/// <p>For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/conditional-requests.html">Add preconditions to S3 operations with conditional requests</a> in the <i>Amazon S3 User Guide</i> or <a href="https://datatracker.ietf.org/doc/rfc7232/">RFC 7232</a>.</p><note>
49/// <p>This functionality is not supported for S3 on Outposts.</p>
50/// </note></li>
51/// <li>
52/// <p><b>S3 Versioning</b> - When you enable versioning for a bucket, if Amazon S3 receives multiple write requests for the same object simultaneously, it stores all versions of the objects. For each write request that is made to the same object, Amazon S3 automatically generates a unique version ID of that object being stored in Amazon S3. You can retrieve, replace, or delete any version of the object. 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>
53/// <p>This functionality is not supported for directory buckets.</p>
54/// </note></li>
55/// </ul>
56/// <dl>
57/// <dt>
58/// Permissions
59/// </dt>
60/// <dd>
61/// <ul>
62/// <li>
63/// <p><b>General purpose bucket permissions</b> - The following permissions are required in your policies when your <code>PutObject</code> request includes specific headers.</p>
64/// <ul>
65/// <li>
66/// <p><b> <code>s3:PutObject</code> </b> - To successfully complete the <code>PutObject</code> request, you must always have the <code>s3:PutObject</code> permission on a bucket to add an object to it.</p></li>
67/// <li>
68/// <p><b> <code>s3:PutObjectAcl</code> </b> - To successfully change the objects ACL of your <code>PutObject</code> request, you must have the <code>s3:PutObjectAcl</code>.</p></li>
69/// <li>
70/// <p><b> <code>s3:PutObjectTagging</code> </b> - To successfully set the tag-set with your <code>PutObject</code> request, you must have the <code>s3:PutObjectTagging</code>.</p></li>
71/// </ul></li>
72/// <li>
73/// <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>
74/// <p>If the object is encrypted with SSE-KMS, you must also have the <code>kms:GenerateDataKey</code> and <code>kms:Decrypt</code> permissions in IAM identity-based policies and KMS key policies for the KMS key.</p></li>
75/// </ul>
76/// </dd>
77/// <dt>
78/// Data integrity with Content-MD5
79/// </dt>
80/// <dd>
81/// <ul>
82/// <li>
83/// <p><b>General purpose bucket</b> - To ensure that data is not corrupted traversing the network, use the <code>Content-MD5</code> header. When you use this header, Amazon S3 checks the object against the provided MD5 value and, if they do not match, Amazon S3 returns an error. Alternatively, when the object's ETag is its MD5 digest, you can calculate the MD5 while putting the object to Amazon S3 and compare the returned ETag to the calculated MD5 value.</p></li>
84/// <li>
85/// <p><b>Directory bucket</b> - This functionality is not supported for directory buckets.</p></li>
86/// </ul>
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>zone-id</i>.<i>region-code</i>.amazonaws.com</code>.</p>
93/// </dd>
94/// </dl>
95/// <dl>
96/// <dt>
97/// Errors
98/// </dt>
99/// <dd>
100/// <ul>
101/// <li>
102/// <p>You might receive an <code>InvalidRequest</code> error for several reasons. Depending on the reason for the error, you might receive one of the following messages:</p>
103/// <ul>
104/// <li>
105/// <p>Cannot specify both a write offset value and user-defined object metadata for existing objects.</p></li>
106/// <li>
107/// <p>Checksum Type mismatch occurred, expected checksum Type: sha1, actual checksum Type: crc32c.</p></li>
108/// <li>
109/// <p>Request body cannot be empty when 'write offset' is specified.</p></li>
110/// </ul></li>
111/// </ul>
112/// </dd>
113/// </dl>
114/// <p>For more information about related Amazon S3 APIs, see the following:</p>
115/// <ul>
116/// <li>
117/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html">CopyObject</a></p></li>
118/// <li>
119/// <p><a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteObject.html">DeleteObject</a></p></li>
120/// </ul><important>
121/// <p>You must URL encode any signed header values that contain spaces. For example, if your header value is <code>my file.txt</code>, containing two spaces after <code>my</code>, you must URL encode this value to <code>my%20%20file.txt</code>.</p>
122/// </important>
123#[derive(::std::fmt::Debug)]
124pub struct PutObjectFluentBuilder {
125 handle: ::std::sync::Arc<crate::client::Handle>,
126 inner: crate::operation::put_object::builders::PutObjectInputBuilder,
127 config_override: ::std::option::Option<crate::config::Builder>,
128}
129impl crate::client::customize::internal::CustomizableSend<crate::operation::put_object::PutObjectOutput, crate::operation::put_object::PutObjectError>
130 for PutObjectFluentBuilder
131{
132 fn send(
133 self,
134 config_override: crate::config::Builder,
135 ) -> crate::client::customize::internal::BoxFuture<
136 crate::client::customize::internal::SendResult<crate::operation::put_object::PutObjectOutput, crate::operation::put_object::PutObjectError>,
137 > {
138 ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
139 }
140}
141impl PutObjectFluentBuilder {
142 /// Creates a new `PutObjectFluentBuilder`.
143 pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
144 Self {
145 handle,
146 inner: ::std::default::Default::default(),
147 config_override: ::std::option::Option::None,
148 }
149 }
150 /// Access the PutObject as a reference.
151 pub fn as_input(&self) -> &crate::operation::put_object::builders::PutObjectInputBuilder {
152 &self.inner
153 }
154 /// Sends the request and returns the response.
155 ///
156 /// If an error occurs, an `SdkError` will be returned with additional details that
157 /// can be matched against.
158 ///
159 /// By default, any retryable failures will be retried twice. Retry behavior
160 /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
161 /// set when configuring the client.
162 pub async fn send(
163 self,
164 ) -> ::std::result::Result<
165 crate::operation::put_object::PutObjectOutput,
166 ::aws_smithy_runtime_api::client::result::SdkError<
167 crate::operation::put_object::PutObjectError,
168 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
169 >,
170 > {
171 let input = self
172 .inner
173 .build()
174 .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
175 let runtime_plugins = crate::operation::put_object::PutObject::operation_runtime_plugins(
176 self.handle.runtime_plugins.clone(),
177 &self.handle.conf,
178 self.config_override,
179 );
180 crate::operation::put_object::PutObject::orchestrate(&runtime_plugins, input).await
181 }
182
183 /// Consumes this builder, creating a customizable operation that can be modified before being sent.
184 pub fn customize(
185 self,
186 ) -> crate::client::customize::CustomizableOperation<
187 crate::operation::put_object::PutObjectOutput,
188 crate::operation::put_object::PutObjectError,
189 Self,
190 > {
191 crate::client::customize::CustomizableOperation::new(self)
192 }
193 pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
194 self.set_config_override(::std::option::Option::Some(config_override.into()));
195 self
196 }
197
198 pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
199 self.config_override = config_override;
200 self
201 }
202 ///
203 /// Creates a presigned request for this operation.
204 ///
205 /// The `presigning_config` provides additional presigning-specific config values, such as the
206 /// amount of time the request should be valid for after creation.
207 ///
208 /// Presigned requests can be given to other users or applications to access a resource or perform
209 /// an operation without having access to the AWS security credentials.
210 ///
211 /// _Important:_ If you're using credentials that can expire, such as those from STS AssumeRole or SSO, then
212 /// the presigned request can only be valid for as long as the credentials used to create it are.
213 ///
214 #[allow(unused_mut)]
215 pub async fn presigned(
216 mut self,
217 presigning_config: crate::presigning::PresigningConfig,
218 ) -> ::std::result::Result<
219 crate::presigning::PresignedRequest,
220 ::aws_smithy_runtime_api::client::result::SdkError<
221 crate::operation::put_object::PutObjectError,
222 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
223 >,
224 > {
225 let runtime_plugins = crate::operation::put_object::PutObject::operation_runtime_plugins(
226 self.handle.runtime_plugins.clone(),
227 &self.handle.conf,
228 self.config_override,
229 )
230 .with_client_plugin(crate::presigning_interceptors::SigV4PresigningRuntimePlugin::new(
231 presigning_config,
232 ::aws_sigv4::http_request::SignableBody::UnsignedPayload,
233 ));
234
235 let input = self
236 .inner
237 .build()
238 .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
239 let mut context = crate::operation::put_object::PutObject::orchestrate_with_stop_point(
240 &runtime_plugins,
241 input,
242 ::aws_smithy_runtime::client::orchestrator::StopPoint::BeforeTransmit,
243 )
244 .await
245 .map_err(|err| {
246 err.map_service_error(|err| {
247 err.downcast::<crate::operation::put_object::PutObjectError>()
248 .expect("correct error type")
249 })
250 })?;
251 let request = context.take_request().expect("request set before transmit");
252 crate::presigning::PresignedRequest::new(request).map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)
253 }
254 /// <p>The canned ACL to apply to the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#CannedACL">Canned ACL</a> in the <i>Amazon S3 User Guide</i>.</p>
255 /// <p>When adding a new object, you can use headers to grant ACL-based permissions to individual Amazon Web Services accounts or to predefined groups defined by Amazon S3. These permissions are then added to the ACL on the object. By default, all objects are private. Only the owner has full access control. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html">Access Control List (ACL) Overview</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-using-rest-api.html">Managing ACLs Using the REST API</a> in the <i>Amazon S3 User Guide</i>.</p>
256 /// <p>If the bucket that you're uploading objects to uses the bucket owner enforced setting for S3 Object Ownership, ACLs are disabled and no longer affect permissions. Buckets that use this setting only accept PUT requests that don't specify an ACL or PUT requests that specify bucket owner full control ACLs, such as the <code>bucket-owner-full-control</code> canned ACL or an equivalent form of this ACL expressed in the XML format. PUT requests that contain other ACLs (for example, custom grants to certain Amazon Web Services accounts) fail and return a <code>400</code> error with the error code <code>AccessControlListNotSupported</code>. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html"> Controlling ownership of objects and disabling ACLs</a> in the <i>Amazon S3 User Guide</i>.</p><note>
257 /// <ul>
258 /// <li>
259 /// <p>This functionality is not supported for directory buckets.</p></li>
260 /// <li>
261 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
262 /// </ul>
263 /// </note>
264 pub fn acl(mut self, input: crate::types::ObjectCannedAcl) -> Self {
265 self.inner = self.inner.acl(input);
266 self
267 }
268 /// <p>The canned ACL to apply to the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#CannedACL">Canned ACL</a> in the <i>Amazon S3 User Guide</i>.</p>
269 /// <p>When adding a new object, you can use headers to grant ACL-based permissions to individual Amazon Web Services accounts or to predefined groups defined by Amazon S3. These permissions are then added to the ACL on the object. By default, all objects are private. Only the owner has full access control. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html">Access Control List (ACL) Overview</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-using-rest-api.html">Managing ACLs Using the REST API</a> in the <i>Amazon S3 User Guide</i>.</p>
270 /// <p>If the bucket that you're uploading objects to uses the bucket owner enforced setting for S3 Object Ownership, ACLs are disabled and no longer affect permissions. Buckets that use this setting only accept PUT requests that don't specify an ACL or PUT requests that specify bucket owner full control ACLs, such as the <code>bucket-owner-full-control</code> canned ACL or an equivalent form of this ACL expressed in the XML format. PUT requests that contain other ACLs (for example, custom grants to certain Amazon Web Services accounts) fail and return a <code>400</code> error with the error code <code>AccessControlListNotSupported</code>. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html"> Controlling ownership of objects and disabling ACLs</a> in the <i>Amazon S3 User Guide</i>.</p><note>
271 /// <ul>
272 /// <li>
273 /// <p>This functionality is not supported for directory buckets.</p></li>
274 /// <li>
275 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
276 /// </ul>
277 /// </note>
278 pub fn set_acl(mut self, input: ::std::option::Option<crate::types::ObjectCannedAcl>) -> Self {
279 self.inner = self.inner.set_acl(input);
280 self
281 }
282 /// <p>The canned ACL to apply to the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#CannedACL">Canned ACL</a> in the <i>Amazon S3 User Guide</i>.</p>
283 /// <p>When adding a new object, you can use headers to grant ACL-based permissions to individual Amazon Web Services accounts or to predefined groups defined by Amazon S3. These permissions are then added to the ACL on the object. By default, all objects are private. Only the owner has full access control. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html">Access Control List (ACL) Overview</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-using-rest-api.html">Managing ACLs Using the REST API</a> in the <i>Amazon S3 User Guide</i>.</p>
284 /// <p>If the bucket that you're uploading objects to uses the bucket owner enforced setting for S3 Object Ownership, ACLs are disabled and no longer affect permissions. Buckets that use this setting only accept PUT requests that don't specify an ACL or PUT requests that specify bucket owner full control ACLs, such as the <code>bucket-owner-full-control</code> canned ACL or an equivalent form of this ACL expressed in the XML format. PUT requests that contain other ACLs (for example, custom grants to certain Amazon Web Services accounts) fail and return a <code>400</code> error with the error code <code>AccessControlListNotSupported</code>. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html"> Controlling ownership of objects and disabling ACLs</a> in the <i>Amazon S3 User Guide</i>.</p><note>
285 /// <ul>
286 /// <li>
287 /// <p>This functionality is not supported for directory buckets.</p></li>
288 /// <li>
289 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
290 /// </ul>
291 /// </note>
292 pub fn get_acl(&self) -> &::std::option::Option<crate::types::ObjectCannedAcl> {
293 self.inner.get_acl()
294 }
295 /// <p>Object data.</p>
296 pub fn body(mut self, input: ::aws_smithy_types::byte_stream::ByteStream) -> Self {
297 self.inner = self.inner.body(input);
298 self
299 }
300 /// <p>Object data.</p>
301 pub fn set_body(mut self, input: ::std::option::Option<::aws_smithy_types::byte_stream::ByteStream>) -> Self {
302 self.inner = self.inner.set_body(input);
303 self
304 }
305 /// <p>Object data.</p>
306 pub fn get_body(&self) -> &::std::option::Option<::aws_smithy_types::byte_stream::ByteStream> {
307 self.inner.get_body()
308 }
309 /// <p>The bucket name to which the PUT action was initiated.</p>
310 /// <p><b>Directory buckets</b> - When you use this operation with a directory bucket, you must use virtual-hosted-style requests in the format <code> <i>Bucket-name</i>.s3express-<i>zone-id</i>.<i>region-code</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Zone (Availability Zone or Local Zone). Bucket names must follow the format <code> <i>bucket-base-name</i>--<i>zone-id</i>--x-s3</code> (for example, <code> <i>amzn-s3-demo-bucket</i>--<i>usw2-az1</i>--x-s3</code>). For information about bucket naming restrictions, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-bucket-naming-rules.html">Directory bucket naming rules</a> in the <i>Amazon S3 User Guide</i>.</p>
311 /// <p><b>Access points</b> - When you use this action with an access point for general purpose buckets, you must provide the alias of the access point in place of the bucket name or specify the access point ARN. When you use this action with an access point for directory buckets, you must provide the access point name in place of the bucket name. When using the access point ARN, you must direct requests to the access point hostname. The access point hostname takes the form <i>AccessPointName</i>-<i>AccountId</i>.s3-accesspoint.<i>Region</i>.amazonaws.com. When using this action with an access point through the Amazon Web Services SDKs, you provide the access point ARN in place of the bucket name. For more information about access point ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-access-points.html">Using access points</a> in the <i>Amazon S3 User Guide</i>.</p><note>
312 /// <p>Object Lambda access points are not supported by directory buckets.</p>
313 /// </note>
314 /// <p><b>S3 on Outposts</b> - When you use this action with S3 on Outposts, you must direct requests to the S3 on Outposts hostname. The S3 on Outposts hostname takes the form <code> <i>AccessPointName</i>-<i>AccountId</i>.<i>outpostID</i>.s3-outposts.<i>Region</i>.amazonaws.com</code>. When you use this action with S3 on Outposts, the destination bucket must be the Outposts access point ARN or the access point alias. For more information about S3 on Outposts, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/S3onOutposts.html">What is S3 on Outposts?</a> in the <i>Amazon S3 User Guide</i>.</p>
315 pub fn bucket(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
316 self.inner = self.inner.bucket(input.into());
317 self
318 }
319 /// <p>The bucket name to which the PUT action was initiated.</p>
320 /// <p><b>Directory buckets</b> - When you use this operation with a directory bucket, you must use virtual-hosted-style requests in the format <code> <i>Bucket-name</i>.s3express-<i>zone-id</i>.<i>region-code</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Zone (Availability Zone or Local Zone). Bucket names must follow the format <code> <i>bucket-base-name</i>--<i>zone-id</i>--x-s3</code> (for example, <code> <i>amzn-s3-demo-bucket</i>--<i>usw2-az1</i>--x-s3</code>). For information about bucket naming restrictions, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-bucket-naming-rules.html">Directory bucket naming rules</a> in the <i>Amazon S3 User Guide</i>.</p>
321 /// <p><b>Access points</b> - When you use this action with an access point for general purpose buckets, you must provide the alias of the access point in place of the bucket name or specify the access point ARN. When you use this action with an access point for directory buckets, you must provide the access point name in place of the bucket name. When using the access point ARN, you must direct requests to the access point hostname. The access point hostname takes the form <i>AccessPointName</i>-<i>AccountId</i>.s3-accesspoint.<i>Region</i>.amazonaws.com. When using this action with an access point through the Amazon Web Services SDKs, you provide the access point ARN in place of the bucket name. For more information about access point ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-access-points.html">Using access points</a> in the <i>Amazon S3 User Guide</i>.</p><note>
322 /// <p>Object Lambda access points are not supported by directory buckets.</p>
323 /// </note>
324 /// <p><b>S3 on Outposts</b> - When you use this action with S3 on Outposts, you must direct requests to the S3 on Outposts hostname. The S3 on Outposts hostname takes the form <code> <i>AccessPointName</i>-<i>AccountId</i>.<i>outpostID</i>.s3-outposts.<i>Region</i>.amazonaws.com</code>. When you use this action with S3 on Outposts, the destination bucket must be the Outposts access point ARN or the access point alias. For more information about S3 on Outposts, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/S3onOutposts.html">What is S3 on Outposts?</a> in the <i>Amazon S3 User Guide</i>.</p>
325 pub fn set_bucket(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
326 self.inner = self.inner.set_bucket(input);
327 self
328 }
329 /// <p>The bucket name to which the PUT action was initiated.</p>
330 /// <p><b>Directory buckets</b> - When you use this operation with a directory bucket, you must use virtual-hosted-style requests in the format <code> <i>Bucket-name</i>.s3express-<i>zone-id</i>.<i>region-code</i>.amazonaws.com</code>. Path-style requests are not supported. Directory bucket names must be unique in the chosen Zone (Availability Zone or Local Zone). Bucket names must follow the format <code> <i>bucket-base-name</i>--<i>zone-id</i>--x-s3</code> (for example, <code> <i>amzn-s3-demo-bucket</i>--<i>usw2-az1</i>--x-s3</code>). For information about bucket naming restrictions, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-bucket-naming-rules.html">Directory bucket naming rules</a> in the <i>Amazon S3 User Guide</i>.</p>
331 /// <p><b>Access points</b> - When you use this action with an access point for general purpose buckets, you must provide the alias of the access point in place of the bucket name or specify the access point ARN. When you use this action with an access point for directory buckets, you must provide the access point name in place of the bucket name. When using the access point ARN, you must direct requests to the access point hostname. The access point hostname takes the form <i>AccessPointName</i>-<i>AccountId</i>.s3-accesspoint.<i>Region</i>.amazonaws.com. When using this action with an access point through the Amazon Web Services SDKs, you provide the access point ARN in place of the bucket name. For more information about access point ARNs, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/using-access-points.html">Using access points</a> in the <i>Amazon S3 User Guide</i>.</p><note>
332 /// <p>Object Lambda access points are not supported by directory buckets.</p>
333 /// </note>
334 /// <p><b>S3 on Outposts</b> - When you use this action with S3 on Outposts, you must direct requests to the S3 on Outposts hostname. The S3 on Outposts hostname takes the form <code> <i>AccessPointName</i>-<i>AccountId</i>.<i>outpostID</i>.s3-outposts.<i>Region</i>.amazonaws.com</code>. When you use this action with S3 on Outposts, the destination bucket must be the Outposts access point ARN or the access point alias. For more information about S3 on Outposts, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/S3onOutposts.html">What is S3 on Outposts?</a> in the <i>Amazon S3 User Guide</i>.</p>
335 pub fn get_bucket(&self) -> &::std::option::Option<::std::string::String> {
336 self.inner.get_bucket()
337 }
338 /// <p>Can be used to specify caching behavior along the request/reply chain. For more information, see <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9">http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9</a>.</p>
339 pub fn cache_control(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
340 self.inner = self.inner.cache_control(input.into());
341 self
342 }
343 /// <p>Can be used to specify caching behavior along the request/reply chain. For more information, see <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9">http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9</a>.</p>
344 pub fn set_cache_control(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
345 self.inner = self.inner.set_cache_control(input);
346 self
347 }
348 /// <p>Can be used to specify caching behavior along the request/reply chain. For more information, see <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9">http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9</a>.</p>
349 pub fn get_cache_control(&self) -> &::std::option::Option<::std::string::String> {
350 self.inner.get_cache_control()
351 }
352 /// <p>Specifies presentational information for the object. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc6266#section-4">https://www.rfc-editor.org/rfc/rfc6266#section-4</a>.</p>
353 pub fn content_disposition(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
354 self.inner = self.inner.content_disposition(input.into());
355 self
356 }
357 /// <p>Specifies presentational information for the object. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc6266#section-4">https://www.rfc-editor.org/rfc/rfc6266#section-4</a>.</p>
358 pub fn set_content_disposition(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
359 self.inner = self.inner.set_content_disposition(input);
360 self
361 }
362 /// <p>Specifies presentational information for the object. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc6266#section-4">https://www.rfc-editor.org/rfc/rfc6266#section-4</a>.</p>
363 pub fn get_content_disposition(&self) -> &::std::option::Option<::std::string::String> {
364 self.inner.get_content_disposition()
365 }
366 /// <p>Specifies what content encodings have been applied to the object and thus what decoding mechanisms must be applied to obtain the media-type referenced by the Content-Type header field. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc9110.html#field.content-encoding">https://www.rfc-editor.org/rfc/rfc9110.html#field.content-encoding</a>.</p>
367 pub fn content_encoding(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
368 self.inner = self.inner.content_encoding(input.into());
369 self
370 }
371 /// <p>Specifies what content encodings have been applied to the object and thus what decoding mechanisms must be applied to obtain the media-type referenced by the Content-Type header field. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc9110.html#field.content-encoding">https://www.rfc-editor.org/rfc/rfc9110.html#field.content-encoding</a>.</p>
372 pub fn set_content_encoding(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
373 self.inner = self.inner.set_content_encoding(input);
374 self
375 }
376 /// <p>Specifies what content encodings have been applied to the object and thus what decoding mechanisms must be applied to obtain the media-type referenced by the Content-Type header field. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc9110.html#field.content-encoding">https://www.rfc-editor.org/rfc/rfc9110.html#field.content-encoding</a>.</p>
377 pub fn get_content_encoding(&self) -> &::std::option::Option<::std::string::String> {
378 self.inner.get_content_encoding()
379 }
380 /// <p>The language the content is in.</p>
381 pub fn content_language(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
382 self.inner = self.inner.content_language(input.into());
383 self
384 }
385 /// <p>The language the content is in.</p>
386 pub fn set_content_language(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
387 self.inner = self.inner.set_content_language(input);
388 self
389 }
390 /// <p>The language the content is in.</p>
391 pub fn get_content_language(&self) -> &::std::option::Option<::std::string::String> {
392 self.inner.get_content_language()
393 }
394 /// <p>Size of the body in bytes. This parameter is useful when the size of the body cannot be determined automatically. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-content-length">https://www.rfc-editor.org/rfc/rfc9110.html#name-content-length</a>.</p>
395 pub fn content_length(mut self, input: i64) -> Self {
396 self.inner = self.inner.content_length(input);
397 self
398 }
399 /// <p>Size of the body in bytes. This parameter is useful when the size of the body cannot be determined automatically. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-content-length">https://www.rfc-editor.org/rfc/rfc9110.html#name-content-length</a>.</p>
400 pub fn set_content_length(mut self, input: ::std::option::Option<i64>) -> Self {
401 self.inner = self.inner.set_content_length(input);
402 self
403 }
404 /// <p>Size of the body in bytes. This parameter is useful when the size of the body cannot be determined automatically. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-content-length">https://www.rfc-editor.org/rfc/rfc9110.html#name-content-length</a>.</p>
405 pub fn get_content_length(&self) -> &::std::option::Option<i64> {
406 self.inner.get_content_length()
407 }
408 /// <p>The Base64 encoded 128-bit <code>MD5</code> digest of the message (without the headers) according to RFC 1864. This header can be used as a message integrity check to verify that the data is the same data that was originally sent. Although it is optional, we recommend using the Content-MD5 mechanism as an end-to-end integrity check. For more information about REST request authentication, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/RESTAuthentication.html">REST Authentication</a>.</p><note>
409 /// <p>The <code>Content-MD5</code> or <code>x-amz-sdk-checksum-algorithm</code> header is required for any request to upload an object with a retention period configured using Amazon S3 Object Lock. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lock-managing.html#object-lock-put-object">Uploading objects to an Object Lock enabled bucket </a> in the <i>Amazon S3 User Guide</i>.</p>
410 /// </note> <note>
411 /// <p>This functionality is not supported for directory buckets.</p>
412 /// </note>
413 pub fn content_md5(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
414 self.inner = self.inner.content_md5(input.into());
415 self
416 }
417 /// <p>The Base64 encoded 128-bit <code>MD5</code> digest of the message (without the headers) according to RFC 1864. This header can be used as a message integrity check to verify that the data is the same data that was originally sent. Although it is optional, we recommend using the Content-MD5 mechanism as an end-to-end integrity check. For more information about REST request authentication, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/RESTAuthentication.html">REST Authentication</a>.</p><note>
418 /// <p>The <code>Content-MD5</code> or <code>x-amz-sdk-checksum-algorithm</code> header is required for any request to upload an object with a retention period configured using Amazon S3 Object Lock. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lock-managing.html#object-lock-put-object">Uploading objects to an Object Lock enabled bucket </a> in the <i>Amazon S3 User Guide</i>.</p>
419 /// </note> <note>
420 /// <p>This functionality is not supported for directory buckets.</p>
421 /// </note>
422 pub fn set_content_md5(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
423 self.inner = self.inner.set_content_md5(input);
424 self
425 }
426 /// <p>The Base64 encoded 128-bit <code>MD5</code> digest of the message (without the headers) according to RFC 1864. This header can be used as a message integrity check to verify that the data is the same data that was originally sent. Although it is optional, we recommend using the Content-MD5 mechanism as an end-to-end integrity check. For more information about REST request authentication, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/RESTAuthentication.html">REST Authentication</a>.</p><note>
427 /// <p>The <code>Content-MD5</code> or <code>x-amz-sdk-checksum-algorithm</code> header is required for any request to upload an object with a retention period configured using Amazon S3 Object Lock. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lock-managing.html#object-lock-put-object">Uploading objects to an Object Lock enabled bucket </a> in the <i>Amazon S3 User Guide</i>.</p>
428 /// </note> <note>
429 /// <p>This functionality is not supported for directory buckets.</p>
430 /// </note>
431 pub fn get_content_md5(&self) -> &::std::option::Option<::std::string::String> {
432 self.inner.get_content_md5()
433 }
434 /// <p>A standard MIME type describing the format of the contents. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-content-type">https://www.rfc-editor.org/rfc/rfc9110.html#name-content-type</a>.</p>
435 pub fn content_type(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
436 self.inner = self.inner.content_type(input.into());
437 self
438 }
439 /// <p>A standard MIME type describing the format of the contents. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-content-type">https://www.rfc-editor.org/rfc/rfc9110.html#name-content-type</a>.</p>
440 pub fn set_content_type(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
441 self.inner = self.inner.set_content_type(input);
442 self
443 }
444 /// <p>A standard MIME type describing the format of the contents. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc9110.html#name-content-type">https://www.rfc-editor.org/rfc/rfc9110.html#name-content-type</a>.</p>
445 pub fn get_content_type(&self) -> &::std::option::Option<::std::string::String> {
446 self.inner.get_content_type()
447 }
448 /// <p>Indicates the algorithm used to create the checksum for the object when you use the SDK. This header will not provide any additional functionality if you don't use the SDK. When you send this header, there must be a corresponding <code>x-amz-checksum-<i>algorithm</i> </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>.</p>
449 /// <p>For the <code>x-amz-checksum-<i>algorithm</i> </code> header, replace <code> <i>algorithm</i> </code> with the supported algorithm from the following list:</p>
450 /// <ul>
451 /// <li>
452 /// <p><code>CRC32</code></p></li>
453 /// <li>
454 /// <p><code>CRC32C</code></p></li>
455 /// <li>
456 /// <p><code>CRC64NVME</code></p></li>
457 /// <li>
458 /// <p><code>MD5</code></p></li>
459 /// <li>
460 /// <p><code>SHA1</code></p></li>
461 /// <li>
462 /// <p><code>SHA256</code></p></li>
463 /// <li>
464 /// <p><code>SHA512</code></p></li>
465 /// <li>
466 /// <p><code>XXHASH3</code></p></li>
467 /// <li>
468 /// <p><code>XXHASH64</code></p></li>
469 /// <li>
470 /// <p><code>XXHASH128</code></p></li>
471 /// </ul>
472 /// <p>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>
473 /// <p>If the individual checksum value you provide through <code>x-amz-checksum-<i>algorithm</i> </code> doesn't match the checksum algorithm you set through <code>x-amz-sdk-checksum-algorithm</code>, Amazon S3 fails the request with a <code>BadDigest</code> error.</p><note>
474 /// <p>The <code>Content-MD5</code> or <code>x-amz-sdk-checksum-algorithm</code> header is required for any request to upload an object with a retention period configured using Amazon S3 Object Lock. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lock-managing.html#object-lock-put-object">Uploading objects to an Object Lock enabled bucket </a> in the <i>Amazon S3 User Guide</i>.</p>
475 /// </note>
476 /// <p>For directory buckets, when you use Amazon Web Services SDKs, <code>CRC32</code> is the default checksum algorithm that's used for performance.</p>
477 pub fn checksum_algorithm(mut self, input: crate::types::ChecksumAlgorithm) -> Self {
478 self.inner = self.inner.checksum_algorithm(input);
479 self
480 }
481 /// <p>Indicates the algorithm used to create the checksum for the object when you use the SDK. This header will not provide any additional functionality if you don't use the SDK. When you send this header, there must be a corresponding <code>x-amz-checksum-<i>algorithm</i> </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>.</p>
482 /// <p>For the <code>x-amz-checksum-<i>algorithm</i> </code> header, replace <code> <i>algorithm</i> </code> with the supported algorithm from the following list:</p>
483 /// <ul>
484 /// <li>
485 /// <p><code>CRC32</code></p></li>
486 /// <li>
487 /// <p><code>CRC32C</code></p></li>
488 /// <li>
489 /// <p><code>CRC64NVME</code></p></li>
490 /// <li>
491 /// <p><code>MD5</code></p></li>
492 /// <li>
493 /// <p><code>SHA1</code></p></li>
494 /// <li>
495 /// <p><code>SHA256</code></p></li>
496 /// <li>
497 /// <p><code>SHA512</code></p></li>
498 /// <li>
499 /// <p><code>XXHASH3</code></p></li>
500 /// <li>
501 /// <p><code>XXHASH64</code></p></li>
502 /// <li>
503 /// <p><code>XXHASH128</code></p></li>
504 /// </ul>
505 /// <p>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>
506 /// <p>If the individual checksum value you provide through <code>x-amz-checksum-<i>algorithm</i> </code> doesn't match the checksum algorithm you set through <code>x-amz-sdk-checksum-algorithm</code>, Amazon S3 fails the request with a <code>BadDigest</code> error.</p><note>
507 /// <p>The <code>Content-MD5</code> or <code>x-amz-sdk-checksum-algorithm</code> header is required for any request to upload an object with a retention period configured using Amazon S3 Object Lock. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lock-managing.html#object-lock-put-object">Uploading objects to an Object Lock enabled bucket </a> in the <i>Amazon S3 User Guide</i>.</p>
508 /// </note>
509 /// <p>For directory buckets, when you use Amazon Web Services SDKs, <code>CRC32</code> is the default checksum algorithm that's used for performance.</p>
510 pub fn set_checksum_algorithm(mut self, input: ::std::option::Option<crate::types::ChecksumAlgorithm>) -> Self {
511 self.inner = self.inner.set_checksum_algorithm(input);
512 self
513 }
514 /// <p>Indicates the algorithm used to create the checksum for the object when you use the SDK. This header will not provide any additional functionality if you don't use the SDK. When you send this header, there must be a corresponding <code>x-amz-checksum-<i>algorithm</i> </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>.</p>
515 /// <p>For the <code>x-amz-checksum-<i>algorithm</i> </code> header, replace <code> <i>algorithm</i> </code> with the supported algorithm from the following list:</p>
516 /// <ul>
517 /// <li>
518 /// <p><code>CRC32</code></p></li>
519 /// <li>
520 /// <p><code>CRC32C</code></p></li>
521 /// <li>
522 /// <p><code>CRC64NVME</code></p></li>
523 /// <li>
524 /// <p><code>MD5</code></p></li>
525 /// <li>
526 /// <p><code>SHA1</code></p></li>
527 /// <li>
528 /// <p><code>SHA256</code></p></li>
529 /// <li>
530 /// <p><code>SHA512</code></p></li>
531 /// <li>
532 /// <p><code>XXHASH3</code></p></li>
533 /// <li>
534 /// <p><code>XXHASH64</code></p></li>
535 /// <li>
536 /// <p><code>XXHASH128</code></p></li>
537 /// </ul>
538 /// <p>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>
539 /// <p>If the individual checksum value you provide through <code>x-amz-checksum-<i>algorithm</i> </code> doesn't match the checksum algorithm you set through <code>x-amz-sdk-checksum-algorithm</code>, Amazon S3 fails the request with a <code>BadDigest</code> error.</p><note>
540 /// <p>The <code>Content-MD5</code> or <code>x-amz-sdk-checksum-algorithm</code> header is required for any request to upload an object with a retention period configured using Amazon S3 Object Lock. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-lock-managing.html#object-lock-put-object">Uploading objects to an Object Lock enabled bucket </a> in the <i>Amazon S3 User Guide</i>.</p>
541 /// </note>
542 /// <p>For directory buckets, when you use Amazon Web Services SDKs, <code>CRC32</code> is the default checksum algorithm that's used for performance.</p>
543 pub fn get_checksum_algorithm(&self) -> &::std::option::Option<crate::types::ChecksumAlgorithm> {
544 self.inner.get_checksum_algorithm()
545 }
546 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
547 pub fn checksum_crc32(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
548 self.inner = self.inner.checksum_crc32(input.into());
549 self
550 }
551 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
552 pub fn set_checksum_crc32(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
553 self.inner = self.inner.set_checksum_crc32(input);
554 self
555 }
556 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
557 pub fn get_checksum_crc32(&self) -> &::std::option::Option<::std::string::String> {
558 self.inner.get_checksum_crc32()
559 }
560 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32C</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
561 pub fn checksum_crc32_c(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
562 self.inner = self.inner.checksum_crc32_c(input.into());
563 self
564 }
565 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32C</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
566 pub fn set_checksum_crc32_c(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
567 self.inner = self.inner.set_checksum_crc32_c(input);
568 self
569 }
570 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 32-bit <code>CRC32C</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
571 pub fn get_checksum_crc32_c(&self) -> &::std::option::Option<::std::string::String> {
572 self.inner.get_checksum_crc32_c()
573 }
574 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>CRC64NVME</code> checksum of the object. The <code>CRC64NVME</code> checksum is always a full object checksum. 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>
575 pub fn checksum_crc64_nvme(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
576 self.inner = self.inner.checksum_crc64_nvme(input.into());
577 self
578 }
579 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>CRC64NVME</code> checksum of the object. The <code>CRC64NVME</code> checksum is always a full object checksum. 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>
580 pub fn set_checksum_crc64_nvme(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
581 self.inner = self.inner.set_checksum_crc64_nvme(input);
582 self
583 }
584 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>CRC64NVME</code> checksum of the object. The <code>CRC64NVME</code> checksum is always a full object checksum. 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>
585 pub fn get_checksum_crc64_nvme(&self) -> &::std::option::Option<::std::string::String> {
586 self.inner.get_checksum_crc64_nvme()
587 }
588 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 160-bit <code>SHA1</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
589 pub fn checksum_sha1(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
590 self.inner = self.inner.checksum_sha1(input.into());
591 self
592 }
593 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 160-bit <code>SHA1</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
594 pub fn set_checksum_sha1(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
595 self.inner = self.inner.set_checksum_sha1(input);
596 self
597 }
598 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 160-bit <code>SHA1</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
599 pub fn get_checksum_sha1(&self) -> &::std::option::Option<::std::string::String> {
600 self.inner.get_checksum_sha1()
601 }
602 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 256-bit <code>SHA256</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
603 pub fn checksum_sha256(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
604 self.inner = self.inner.checksum_sha256(input.into());
605 self
606 }
607 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 256-bit <code>SHA256</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
608 pub fn set_checksum_sha256(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
609 self.inner = self.inner.set_checksum_sha256(input);
610 self
611 }
612 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 256-bit <code>SHA256</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity</a> in the <i>Amazon S3 User Guide</i>.</p>
613 pub fn get_checksum_sha256(&self) -> &::std::option::Option<::std::string::String> {
614 self.inner.get_checksum_sha256()
615 }
616 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 512-bit <code>SHA512</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
617 pub fn checksum_sha512(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
618 self.inner = self.inner.checksum_sha512(input.into());
619 self
620 }
621 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 512-bit <code>SHA512</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
622 pub fn set_checksum_sha512(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
623 self.inner = self.inner.set_checksum_sha512(input);
624 self
625 }
626 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 512-bit <code>SHA512</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
627 pub fn get_checksum_sha512(&self) -> &::std::option::Option<::std::string::String> {
628 self.inner.get_checksum_sha512()
629 }
630 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 128-bit <code>MD5</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
631 pub fn checksum_md5(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
632 self.inner = self.inner.checksum_md5(input.into());
633 self
634 }
635 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 128-bit <code>MD5</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
636 pub fn set_checksum_md5(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
637 self.inner = self.inner.set_checksum_md5(input);
638 self
639 }
640 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 128-bit <code>MD5</code> digest of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
641 pub fn get_checksum_md5(&self) -> &::std::option::Option<::std::string::String> {
642 self.inner.get_checksum_md5()
643 }
644 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>XXHASH64</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
645 pub fn checksum_xxhash64(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
646 self.inner = self.inner.checksum_xxhash64(input.into());
647 self
648 }
649 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>XXHASH64</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
650 pub fn set_checksum_xxhash64(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
651 self.inner = self.inner.set_checksum_xxhash64(input);
652 self
653 }
654 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>XXHASH64</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
655 pub fn get_checksum_xxhash64(&self) -> &::std::option::Option<::std::string::String> {
656 self.inner.get_checksum_xxhash64()
657 }
658 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>XXHASH3</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
659 pub fn checksum_xxhash3(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
660 self.inner = self.inner.checksum_xxhash3(input.into());
661 self
662 }
663 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>XXHASH3</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
664 pub fn set_checksum_xxhash3(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
665 self.inner = self.inner.set_checksum_xxhash3(input);
666 self
667 }
668 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 64-bit <code>XXHASH3</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
669 pub fn get_checksum_xxhash3(&self) -> &::std::option::Option<::std::string::String> {
670 self.inner.get_checksum_xxhash3()
671 }
672 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 128-bit <code>XXHASH128</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
673 pub fn checksum_xxhash128(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
674 self.inner = self.inner.checksum_xxhash128(input.into());
675 self
676 }
677 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 128-bit <code>XXHASH128</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
678 pub fn set_checksum_xxhash128(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
679 self.inner = self.inner.set_checksum_xxhash128(input);
680 self
681 }
682 /// <p>This header can be used as a data integrity check to verify that the data received is the same data that was originally sent. This header specifies the Base64 encoded, 128-bit <code>XXHASH128</code> checksum of the object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html">Checking object integrity in the Amazon S3 User Guide</a>.</p>
683 pub fn get_checksum_xxhash128(&self) -> &::std::option::Option<::std::string::String> {
684 self.inner.get_checksum_xxhash128()
685 }
686 /// <p>The date and time at which the object is no longer cacheable. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc7234#section-5.3">https://www.rfc-editor.org/rfc/rfc7234#section-5.3</a>.</p>
687 pub fn expires(mut self, input: ::aws_smithy_types::DateTime) -> Self {
688 self.inner = self.inner.expires(input);
689 self
690 }
691 /// <p>The date and time at which the object is no longer cacheable. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc7234#section-5.3">https://www.rfc-editor.org/rfc/rfc7234#section-5.3</a>.</p>
692 pub fn set_expires(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
693 self.inner = self.inner.set_expires(input);
694 self
695 }
696 /// <p>The date and time at which the object is no longer cacheable. For more information, see <a href="https://www.rfc-editor.org/rfc/rfc7234#section-5.3">https://www.rfc-editor.org/rfc/rfc7234#section-5.3</a>.</p>
697 pub fn get_expires(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
698 self.inner.get_expires()
699 }
700 /// <p>Uploads the object only if the ETag (entity tag) value provided during the WRITE operation matches the ETag of the object in S3. If the ETag values do not match, the operation returns a <code>412 Precondition Failed</code> error.</p>
701 /// <p>If a conflicting operation occurs during the upload S3 returns a <code>409 ConditionalRequestConflict</code> response. On a 409 failure you should fetch the object's ETag and retry the upload.</p>
702 /// <p>Expects the ETag value as a string.</p>
703 /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>, or <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/conditional-requests.html">Conditional requests</a> in the <i>Amazon S3 User Guide</i>.</p>
704 pub fn if_match(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
705 self.inner = self.inner.if_match(input.into());
706 self
707 }
708 /// <p>Uploads the object only if the ETag (entity tag) value provided during the WRITE operation matches the ETag of the object in S3. If the ETag values do not match, the operation returns a <code>412 Precondition Failed</code> error.</p>
709 /// <p>If a conflicting operation occurs during the upload S3 returns a <code>409 ConditionalRequestConflict</code> response. On a 409 failure you should fetch the object's ETag and retry the upload.</p>
710 /// <p>Expects the ETag value as a string.</p>
711 /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>, or <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/conditional-requests.html">Conditional requests</a> in the <i>Amazon S3 User Guide</i>.</p>
712 pub fn set_if_match(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
713 self.inner = self.inner.set_if_match(input);
714 self
715 }
716 /// <p>Uploads the object only if the ETag (entity tag) value provided during the WRITE operation matches the ETag of the object in S3. If the ETag values do not match, the operation returns a <code>412 Precondition Failed</code> error.</p>
717 /// <p>If a conflicting operation occurs during the upload S3 returns a <code>409 ConditionalRequestConflict</code> response. On a 409 failure you should fetch the object's ETag and retry the upload.</p>
718 /// <p>Expects the ETag value as a string.</p>
719 /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>, or <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/conditional-requests.html">Conditional requests</a> in the <i>Amazon S3 User Guide</i>.</p>
720 pub fn get_if_match(&self) -> &::std::option::Option<::std::string::String> {
721 self.inner.get_if_match()
722 }
723 /// <p>Uploads the object only if the object key name does not already exist in the bucket specified. Otherwise, Amazon S3 returns a <code>412 Precondition Failed</code> error.</p>
724 /// <p>If a conflicting operation occurs during the upload S3 returns a <code>409 ConditionalRequestConflict</code> response. On a 409 failure you should retry the upload.</p>
725 /// <p>Expects the '*' (asterisk) character.</p>
726 /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>, or <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/conditional-requests.html">Conditional requests</a> in the <i>Amazon S3 User Guide</i>.</p>
727 pub fn if_none_match(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
728 self.inner = self.inner.if_none_match(input.into());
729 self
730 }
731 /// <p>Uploads the object only if the object key name does not already exist in the bucket specified. Otherwise, Amazon S3 returns a <code>412 Precondition Failed</code> error.</p>
732 /// <p>If a conflicting operation occurs during the upload S3 returns a <code>409 ConditionalRequestConflict</code> response. On a 409 failure you should retry the upload.</p>
733 /// <p>Expects the '*' (asterisk) character.</p>
734 /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>, or <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/conditional-requests.html">Conditional requests</a> in the <i>Amazon S3 User Guide</i>.</p>
735 pub fn set_if_none_match(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
736 self.inner = self.inner.set_if_none_match(input);
737 self
738 }
739 /// <p>Uploads the object only if the object key name does not already exist in the bucket specified. Otherwise, Amazon S3 returns a <code>412 Precondition Failed</code> error.</p>
740 /// <p>If a conflicting operation occurs during the upload S3 returns a <code>409 ConditionalRequestConflict</code> response. On a 409 failure you should retry the upload.</p>
741 /// <p>Expects the '*' (asterisk) character.</p>
742 /// <p>For more information about conditional requests, see <a href="https://tools.ietf.org/html/rfc7232">RFC 7232</a>, or <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/conditional-requests.html">Conditional requests</a> in the <i>Amazon S3 User Guide</i>.</p>
743 pub fn get_if_none_match(&self) -> &::std::option::Option<::std::string::String> {
744 self.inner.get_if_none_match()
745 }
746 /// <p>Gives the grantee READ, READ_ACP, and WRITE_ACP permissions on the object.</p><note>
747 /// <ul>
748 /// <li>
749 /// <p>This functionality is not supported for directory buckets.</p></li>
750 /// <li>
751 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
752 /// </ul>
753 /// </note>
754 pub fn grant_full_control(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
755 self.inner = self.inner.grant_full_control(input.into());
756 self
757 }
758 /// <p>Gives the grantee READ, READ_ACP, and WRITE_ACP permissions on the object.</p><note>
759 /// <ul>
760 /// <li>
761 /// <p>This functionality is not supported for directory buckets.</p></li>
762 /// <li>
763 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
764 /// </ul>
765 /// </note>
766 pub fn set_grant_full_control(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
767 self.inner = self.inner.set_grant_full_control(input);
768 self
769 }
770 /// <p>Gives the grantee READ, READ_ACP, and WRITE_ACP permissions on the object.</p><note>
771 /// <ul>
772 /// <li>
773 /// <p>This functionality is not supported for directory buckets.</p></li>
774 /// <li>
775 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
776 /// </ul>
777 /// </note>
778 pub fn get_grant_full_control(&self) -> &::std::option::Option<::std::string::String> {
779 self.inner.get_grant_full_control()
780 }
781 /// <p>Allows grantee to read the object data and its metadata.</p><note>
782 /// <ul>
783 /// <li>
784 /// <p>This functionality is not supported for directory buckets.</p></li>
785 /// <li>
786 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
787 /// </ul>
788 /// </note>
789 pub fn grant_read(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
790 self.inner = self.inner.grant_read(input.into());
791 self
792 }
793 /// <p>Allows grantee to read the object data and its metadata.</p><note>
794 /// <ul>
795 /// <li>
796 /// <p>This functionality is not supported for directory buckets.</p></li>
797 /// <li>
798 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
799 /// </ul>
800 /// </note>
801 pub fn set_grant_read(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
802 self.inner = self.inner.set_grant_read(input);
803 self
804 }
805 /// <p>Allows grantee to read the object data and its metadata.</p><note>
806 /// <ul>
807 /// <li>
808 /// <p>This functionality is not supported for directory buckets.</p></li>
809 /// <li>
810 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
811 /// </ul>
812 /// </note>
813 pub fn get_grant_read(&self) -> &::std::option::Option<::std::string::String> {
814 self.inner.get_grant_read()
815 }
816 /// <p>Allows grantee to read the object ACL.</p><note>
817 /// <ul>
818 /// <li>
819 /// <p>This functionality is not supported for directory buckets.</p></li>
820 /// <li>
821 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
822 /// </ul>
823 /// </note>
824 pub fn grant_read_acp(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
825 self.inner = self.inner.grant_read_acp(input.into());
826 self
827 }
828 /// <p>Allows grantee to read the object ACL.</p><note>
829 /// <ul>
830 /// <li>
831 /// <p>This functionality is not supported for directory buckets.</p></li>
832 /// <li>
833 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
834 /// </ul>
835 /// </note>
836 pub fn set_grant_read_acp(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
837 self.inner = self.inner.set_grant_read_acp(input);
838 self
839 }
840 /// <p>Allows grantee to read the object ACL.</p><note>
841 /// <ul>
842 /// <li>
843 /// <p>This functionality is not supported for directory buckets.</p></li>
844 /// <li>
845 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
846 /// </ul>
847 /// </note>
848 pub fn get_grant_read_acp(&self) -> &::std::option::Option<::std::string::String> {
849 self.inner.get_grant_read_acp()
850 }
851 /// <p>Allows grantee to write the ACL for the applicable object.</p><note>
852 /// <ul>
853 /// <li>
854 /// <p>This functionality is not supported for directory buckets.</p></li>
855 /// <li>
856 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
857 /// </ul>
858 /// </note>
859 pub fn grant_write_acp(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
860 self.inner = self.inner.grant_write_acp(input.into());
861 self
862 }
863 /// <p>Allows grantee to write the ACL for the applicable object.</p><note>
864 /// <ul>
865 /// <li>
866 /// <p>This functionality is not supported for directory buckets.</p></li>
867 /// <li>
868 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
869 /// </ul>
870 /// </note>
871 pub fn set_grant_write_acp(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
872 self.inner = self.inner.set_grant_write_acp(input);
873 self
874 }
875 /// <p>Allows grantee to write the ACL for the applicable object.</p><note>
876 /// <ul>
877 /// <li>
878 /// <p>This functionality is not supported for directory buckets.</p></li>
879 /// <li>
880 /// <p>This functionality is not supported for Amazon S3 on Outposts.</p></li>
881 /// </ul>
882 /// </note>
883 pub fn get_grant_write_acp(&self) -> &::std::option::Option<::std::string::String> {
884 self.inner.get_grant_write_acp()
885 }
886 /// <p>Object key for which the PUT action was initiated.</p>
887 pub fn key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
888 self.inner = self.inner.key(input.into());
889 self
890 }
891 /// <p>Object key for which the PUT action was initiated.</p>
892 pub fn set_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
893 self.inner = self.inner.set_key(input);
894 self
895 }
896 /// <p>Object key for which the PUT action was initiated.</p>
897 pub fn get_key(&self) -> &::std::option::Option<::std::string::String> {
898 self.inner.get_key()
899 }
900 /// <p>Specifies the offset for appending data to existing objects in bytes. The offset must be equal to the size of the existing object being appended to. If no object exists, setting this header to 0 will create a new object.</p><note>
901 /// <p>This functionality is only supported for objects in the Amazon S3 Express One Zone storage class in directory buckets.</p>
902 /// </note>
903 pub fn write_offset_bytes(mut self, input: i64) -> Self {
904 self.inner = self.inner.write_offset_bytes(input);
905 self
906 }
907 /// <p>Specifies the offset for appending data to existing objects in bytes. The offset must be equal to the size of the existing object being appended to. If no object exists, setting this header to 0 will create a new object.</p><note>
908 /// <p>This functionality is only supported for objects in the Amazon S3 Express One Zone storage class in directory buckets.</p>
909 /// </note>
910 pub fn set_write_offset_bytes(mut self, input: ::std::option::Option<i64>) -> Self {
911 self.inner = self.inner.set_write_offset_bytes(input);
912 self
913 }
914 /// <p>Specifies the offset for appending data to existing objects in bytes. The offset must be equal to the size of the existing object being appended to. If no object exists, setting this header to 0 will create a new object.</p><note>
915 /// <p>This functionality is only supported for objects in the Amazon S3 Express One Zone storage class in directory buckets.</p>
916 /// </note>
917 pub fn get_write_offset_bytes(&self) -> &::std::option::Option<i64> {
918 self.inner.get_write_offset_bytes()
919 }
920 ///
921 /// Adds a key-value pair to `Metadata`.
922 ///
923 /// To override the contents of this collection use [`set_metadata`](Self::set_metadata).
924 ///
925 /// <p>A map of metadata to store with the object in S3.</p>
926 pub fn metadata(mut self, k: impl ::std::convert::Into<::std::string::String>, v: impl ::std::convert::Into<::std::string::String>) -> Self {
927 self.inner = self.inner.metadata(k.into(), v.into());
928 self
929 }
930 /// <p>A map of metadata to store with the object in S3.</p>
931 pub fn set_metadata(mut self, input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>) -> Self {
932 self.inner = self.inner.set_metadata(input);
933 self
934 }
935 /// <p>A map of metadata to store with the object in S3.</p>
936 pub fn get_metadata(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
937 self.inner.get_metadata()
938 }
939 /// <p>The server-side encryption algorithm that was used when you store this object in Amazon S3 or Amazon FSx.</p>
940 /// <ul>
941 /// <li>
942 /// <p><b>General purpose buckets </b> - You have four mutually exclusive options to protect data using server-side encryption in Amazon S3, depending on how you choose to manage the encryption keys. Specifically, the encryption key options are Amazon S3 managed keys (SSE-S3), Amazon Web Services KMS keys (SSE-KMS or DSSE-KMS), and customer-provided keys (SSE-C). Amazon S3 encrypts data with server-side encryption by using Amazon S3 managed keys (SSE-S3) by default. You can optionally tell Amazon S3 to encrypt data at rest by using server-side encryption with other key options. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingServerSideEncryption.html">Using Server-Side Encryption</a> in the <i>Amazon S3 User Guide</i>.</p></li>
943 /// <li>
944 /// <p><b>Directory buckets </b> - For directory buckets, there are only two supported options for server-side encryption: server-side encryption with Amazon S3 managed keys (SSE-S3) (<code>AES256</code>) and server-side encryption with KMS keys (SSE-KMS) (<code>aws:kms</code>). We recommend that the bucket's default encryption uses the desired encryption configuration and you don't override the bucket default encryption in your <code>CreateSession</code> requests or <code>PUT</code> object requests. Then, new objects are automatically encrypted with the desired encryption settings. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html">Protecting data with server-side encryption</a> in the <i>Amazon S3 User Guide</i>. For more information about the encryption overriding behaviors in directory buckets, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-specifying-kms-encryption.html">Specifying server-side encryption with KMS for new object uploads</a>.</p>
945 /// <p>In the Zonal endpoint API calls (except <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html">CopyObject</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html">UploadPartCopy</a>) using the REST API, the encryption request headers must match the encryption settings that are specified in the <code>CreateSession</code> request. You can't override the values of the encryption settings (<code>x-amz-server-side-encryption</code>, <code>x-amz-server-side-encryption-aws-kms-key-id</code>, <code>x-amz-server-side-encryption-context</code>, and <code>x-amz-server-side-encryption-bucket-key-enabled</code>) that are specified in the <code>CreateSession</code> request. You don't need to explicitly specify these encryption settings values in Zonal endpoint API calls, and Amazon S3 will use the encryption settings values from the <code>CreateSession</code> request to protect new objects in the directory bucket.</p><note>
946 /// <p>When you use the CLI or the Amazon Web Services SDKs, for <code>CreateSession</code>, the session token refreshes automatically to avoid service interruptions when a session expires. The CLI or the Amazon Web Services SDKs use the bucket's default encryption configuration for the <code>CreateSession</code> request. It's not supported to override the encryption settings values in the <code>CreateSession</code> request. So in the Zonal endpoint API calls (except <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html">CopyObject</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html">UploadPartCopy</a>), the encryption request headers must match the default encryption configuration of the directory bucket.</p>
947 /// </note></li>
948 /// <li>
949 /// <p><b>S3 access points for Amazon FSx </b> - 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>. All Amazon FSx file systems have encryption configured by default and are encrypted at rest. Data is automatically encrypted before being written to the file system, and automatically decrypted as it is read. These processes are handled transparently by Amazon FSx.</p></li>
950 /// </ul>
951 pub fn server_side_encryption(mut self, input: crate::types::ServerSideEncryption) -> Self {
952 self.inner = self.inner.server_side_encryption(input);
953 self
954 }
955 /// <p>The server-side encryption algorithm that was used when you store this object in Amazon S3 or Amazon FSx.</p>
956 /// <ul>
957 /// <li>
958 /// <p><b>General purpose buckets </b> - You have four mutually exclusive options to protect data using server-side encryption in Amazon S3, depending on how you choose to manage the encryption keys. Specifically, the encryption key options are Amazon S3 managed keys (SSE-S3), Amazon Web Services KMS keys (SSE-KMS or DSSE-KMS), and customer-provided keys (SSE-C). Amazon S3 encrypts data with server-side encryption by using Amazon S3 managed keys (SSE-S3) by default. You can optionally tell Amazon S3 to encrypt data at rest by using server-side encryption with other key options. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingServerSideEncryption.html">Using Server-Side Encryption</a> in the <i>Amazon S3 User Guide</i>.</p></li>
959 /// <li>
960 /// <p><b>Directory buckets </b> - For directory buckets, there are only two supported options for server-side encryption: server-side encryption with Amazon S3 managed keys (SSE-S3) (<code>AES256</code>) and server-side encryption with KMS keys (SSE-KMS) (<code>aws:kms</code>). We recommend that the bucket's default encryption uses the desired encryption configuration and you don't override the bucket default encryption in your <code>CreateSession</code> requests or <code>PUT</code> object requests. Then, new objects are automatically encrypted with the desired encryption settings. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html">Protecting data with server-side encryption</a> in the <i>Amazon S3 User Guide</i>. For more information about the encryption overriding behaviors in directory buckets, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-specifying-kms-encryption.html">Specifying server-side encryption with KMS for new object uploads</a>.</p>
961 /// <p>In the Zonal endpoint API calls (except <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html">CopyObject</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html">UploadPartCopy</a>) using the REST API, the encryption request headers must match the encryption settings that are specified in the <code>CreateSession</code> request. You can't override the values of the encryption settings (<code>x-amz-server-side-encryption</code>, <code>x-amz-server-side-encryption-aws-kms-key-id</code>, <code>x-amz-server-side-encryption-context</code>, and <code>x-amz-server-side-encryption-bucket-key-enabled</code>) that are specified in the <code>CreateSession</code> request. You don't need to explicitly specify these encryption settings values in Zonal endpoint API calls, and Amazon S3 will use the encryption settings values from the <code>CreateSession</code> request to protect new objects in the directory bucket.</p><note>
962 /// <p>When you use the CLI or the Amazon Web Services SDKs, for <code>CreateSession</code>, the session token refreshes automatically to avoid service interruptions when a session expires. The CLI or the Amazon Web Services SDKs use the bucket's default encryption configuration for the <code>CreateSession</code> request. It's not supported to override the encryption settings values in the <code>CreateSession</code> request. So in the Zonal endpoint API calls (except <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html">CopyObject</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html">UploadPartCopy</a>), the encryption request headers must match the default encryption configuration of the directory bucket.</p>
963 /// </note></li>
964 /// <li>
965 /// <p><b>S3 access points for Amazon FSx </b> - 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>. All Amazon FSx file systems have encryption configured by default and are encrypted at rest. Data is automatically encrypted before being written to the file system, and automatically decrypted as it is read. These processes are handled transparently by Amazon FSx.</p></li>
966 /// </ul>
967 pub fn set_server_side_encryption(mut self, input: ::std::option::Option<crate::types::ServerSideEncryption>) -> Self {
968 self.inner = self.inner.set_server_side_encryption(input);
969 self
970 }
971 /// <p>The server-side encryption algorithm that was used when you store this object in Amazon S3 or Amazon FSx.</p>
972 /// <ul>
973 /// <li>
974 /// <p><b>General purpose buckets </b> - You have four mutually exclusive options to protect data using server-side encryption in Amazon S3, depending on how you choose to manage the encryption keys. Specifically, the encryption key options are Amazon S3 managed keys (SSE-S3), Amazon Web Services KMS keys (SSE-KMS or DSSE-KMS), and customer-provided keys (SSE-C). Amazon S3 encrypts data with server-side encryption by using Amazon S3 managed keys (SSE-S3) by default. You can optionally tell Amazon S3 to encrypt data at rest by using server-side encryption with other key options. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingServerSideEncryption.html">Using Server-Side Encryption</a> in the <i>Amazon S3 User Guide</i>.</p></li>
975 /// <li>
976 /// <p><b>Directory buckets </b> - For directory buckets, there are only two supported options for server-side encryption: server-side encryption with Amazon S3 managed keys (SSE-S3) (<code>AES256</code>) and server-side encryption with KMS keys (SSE-KMS) (<code>aws:kms</code>). We recommend that the bucket's default encryption uses the desired encryption configuration and you don't override the bucket default encryption in your <code>CreateSession</code> requests or <code>PUT</code> object requests. Then, new objects are automatically encrypted with the desired encryption settings. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-serv-side-encryption.html">Protecting data with server-side encryption</a> in the <i>Amazon S3 User Guide</i>. For more information about the encryption overriding behaviors in directory buckets, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-specifying-kms-encryption.html">Specifying server-side encryption with KMS for new object uploads</a>.</p>
977 /// <p>In the Zonal endpoint API calls (except <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html">CopyObject</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html">UploadPartCopy</a>) using the REST API, the encryption request headers must match the encryption settings that are specified in the <code>CreateSession</code> request. You can't override the values of the encryption settings (<code>x-amz-server-side-encryption</code>, <code>x-amz-server-side-encryption-aws-kms-key-id</code>, <code>x-amz-server-side-encryption-context</code>, and <code>x-amz-server-side-encryption-bucket-key-enabled</code>) that are specified in the <code>CreateSession</code> request. You don't need to explicitly specify these encryption settings values in Zonal endpoint API calls, and Amazon S3 will use the encryption settings values from the <code>CreateSession</code> request to protect new objects in the directory bucket.</p><note>
978 /// <p>When you use the CLI or the Amazon Web Services SDKs, for <code>CreateSession</code>, the session token refreshes automatically to avoid service interruptions when a session expires. The CLI or the Amazon Web Services SDKs use the bucket's default encryption configuration for the <code>CreateSession</code> request. It's not supported to override the encryption settings values in the <code>CreateSession</code> request. So in the Zonal endpoint API calls (except <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html">CopyObject</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html">UploadPartCopy</a>), the encryption request headers must match the default encryption configuration of the directory bucket.</p>
979 /// </note></li>
980 /// <li>
981 /// <p><b>S3 access points for Amazon FSx </b> - 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>. All Amazon FSx file systems have encryption configured by default and are encrypted at rest. Data is automatically encrypted before being written to the file system, and automatically decrypted as it is read. These processes are handled transparently by Amazon FSx.</p></li>
982 /// </ul>
983 pub fn get_server_side_encryption(&self) -> &::std::option::Option<crate::types::ServerSideEncryption> {
984 self.inner.get_server_side_encryption()
985 }
986 /// <p>By default, Amazon S3 uses the STANDARD Storage Class to store newly created objects. The STANDARD storage class provides high durability and high availability. Depending on performance needs, you can specify a different Storage Class. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-class-intro.html">Storage Classes</a> in the <i>Amazon S3 User Guide</i>.</p><note>
987 /// <ul>
988 /// <li>
989 /// <p>Directory buckets only support <code>EXPRESS_ONEZONE</code> (the S3 Express One Zone storage class) in Availability Zones and <code>ONEZONE_IA</code> (the S3 One Zone-Infrequent Access storage class) in Dedicated Local Zones.</p></li>
990 /// <li>
991 /// <p>Amazon S3 on Outposts only uses the OUTPOSTS Storage Class.</p></li>
992 /// </ul>
993 /// </note>
994 pub fn storage_class(mut self, input: crate::types::StorageClass) -> Self {
995 self.inner = self.inner.storage_class(input);
996 self
997 }
998 /// <p>By default, Amazon S3 uses the STANDARD Storage Class to store newly created objects. The STANDARD storage class provides high durability and high availability. Depending on performance needs, you can specify a different Storage Class. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-class-intro.html">Storage Classes</a> in the <i>Amazon S3 User Guide</i>.</p><note>
999 /// <ul>
1000 /// <li>
1001 /// <p>Directory buckets only support <code>EXPRESS_ONEZONE</code> (the S3 Express One Zone storage class) in Availability Zones and <code>ONEZONE_IA</code> (the S3 One Zone-Infrequent Access storage class) in Dedicated Local Zones.</p></li>
1002 /// <li>
1003 /// <p>Amazon S3 on Outposts only uses the OUTPOSTS Storage Class.</p></li>
1004 /// </ul>
1005 /// </note>
1006 pub fn set_storage_class(mut self, input: ::std::option::Option<crate::types::StorageClass>) -> Self {
1007 self.inner = self.inner.set_storage_class(input);
1008 self
1009 }
1010 /// <p>By default, Amazon S3 uses the STANDARD Storage Class to store newly created objects. The STANDARD storage class provides high durability and high availability. Depending on performance needs, you can specify a different Storage Class. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/storage-class-intro.html">Storage Classes</a> in the <i>Amazon S3 User Guide</i>.</p><note>
1011 /// <ul>
1012 /// <li>
1013 /// <p>Directory buckets only support <code>EXPRESS_ONEZONE</code> (the S3 Express One Zone storage class) in Availability Zones and <code>ONEZONE_IA</code> (the S3 One Zone-Infrequent Access storage class) in Dedicated Local Zones.</p></li>
1014 /// <li>
1015 /// <p>Amazon S3 on Outposts only uses the OUTPOSTS Storage Class.</p></li>
1016 /// </ul>
1017 /// </note>
1018 pub fn get_storage_class(&self) -> &::std::option::Option<crate::types::StorageClass> {
1019 self.inner.get_storage_class()
1020 }
1021 /// <p>If the bucket is configured as a website, redirects requests for this object to another object in the same bucket or to an external URL. Amazon S3 stores the value of this header in the object metadata. For information about object metadata, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingMetadata.html">Object Key and Metadata</a> in the <i>Amazon S3 User Guide</i>.</p>
1022 /// <p>In the following example, the request header sets the redirect to an object (anotherPage.html) in the same bucket:</p>
1023 /// <p><code>x-amz-website-redirect-location: /anotherPage.html</code></p>
1024 /// <p>In the following example, the request header sets the object redirect to another website:</p>
1025 /// <p><code>x-amz-website-redirect-location: http://www.example.com/</code></p>
1026 /// <p>For more information about website hosting in Amazon S3, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/WebsiteHosting.html">Hosting Websites on Amazon S3</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/how-to-page-redirect.html">How to Configure Website Page Redirects</a> in the <i>Amazon S3 User Guide</i>.</p><note>
1027 /// <p>This functionality is not supported for directory buckets.</p>
1028 /// </note>
1029 pub fn website_redirect_location(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
1030 self.inner = self.inner.website_redirect_location(input.into());
1031 self
1032 }
1033 /// <p>If the bucket is configured as a website, redirects requests for this object to another object in the same bucket or to an external URL. Amazon S3 stores the value of this header in the object metadata. For information about object metadata, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingMetadata.html">Object Key and Metadata</a> in the <i>Amazon S3 User Guide</i>.</p>
1034 /// <p>In the following example, the request header sets the redirect to an object (anotherPage.html) in the same bucket:</p>
1035 /// <p><code>x-amz-website-redirect-location: /anotherPage.html</code></p>
1036 /// <p>In the following example, the request header sets the object redirect to another website:</p>
1037 /// <p><code>x-amz-website-redirect-location: http://www.example.com/</code></p>
1038 /// <p>For more information about website hosting in Amazon S3, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/WebsiteHosting.html">Hosting Websites on Amazon S3</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/how-to-page-redirect.html">How to Configure Website Page Redirects</a> in the <i>Amazon S3 User Guide</i>.</p><note>
1039 /// <p>This functionality is not supported for directory buckets.</p>
1040 /// </note>
1041 pub fn set_website_redirect_location(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
1042 self.inner = self.inner.set_website_redirect_location(input);
1043 self
1044 }
1045 /// <p>If the bucket is configured as a website, redirects requests for this object to another object in the same bucket or to an external URL. Amazon S3 stores the value of this header in the object metadata. For information about object metadata, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/UsingMetadata.html">Object Key and Metadata</a> in the <i>Amazon S3 User Guide</i>.</p>
1046 /// <p>In the following example, the request header sets the redirect to an object (anotherPage.html) in the same bucket:</p>
1047 /// <p><code>x-amz-website-redirect-location: /anotherPage.html</code></p>
1048 /// <p>In the following example, the request header sets the object redirect to another website:</p>
1049 /// <p><code>x-amz-website-redirect-location: http://www.example.com/</code></p>
1050 /// <p>For more information about website hosting in Amazon S3, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/WebsiteHosting.html">Hosting Websites on Amazon S3</a> and <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/how-to-page-redirect.html">How to Configure Website Page Redirects</a> in the <i>Amazon S3 User Guide</i>.</p><note>
1051 /// <p>This functionality is not supported for directory buckets.</p>
1052 /// </note>
1053 pub fn get_website_redirect_location(&self) -> &::std::option::Option<::std::string::String> {
1054 self.inner.get_website_redirect_location()
1055 }
1056 /// <p>Specifies the algorithm to use when encrypting the object (for example, <code>AES256</code>).</p><note>
1057 /// <p>This functionality is not supported for directory buckets.</p>
1058 /// </note>
1059 pub fn sse_customer_algorithm(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
1060 self.inner = self.inner.sse_customer_algorithm(input.into());
1061 self
1062 }
1063 /// <p>Specifies the algorithm to use when encrypting the object (for example, <code>AES256</code>).</p><note>
1064 /// <p>This functionality is not supported for directory buckets.</p>
1065 /// </note>
1066 pub fn set_sse_customer_algorithm(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
1067 self.inner = self.inner.set_sse_customer_algorithm(input);
1068 self
1069 }
1070 /// <p>Specifies the algorithm to use when encrypting the object (for example, <code>AES256</code>).</p><note>
1071 /// <p>This functionality is not supported for directory buckets.</p>
1072 /// </note>
1073 pub fn get_sse_customer_algorithm(&self) -> &::std::option::Option<::std::string::String> {
1074 self.inner.get_sse_customer_algorithm()
1075 }
1076 /// <p>Specifies the customer-provided encryption key for Amazon S3 to use in encrypting data. This value is used to store the object and then it is discarded; Amazon S3 does not store the encryption key. The key must be appropriate for use with the algorithm specified in the <code>x-amz-server-side-encryption-customer-algorithm</code> header.</p><note>
1077 /// <p>This functionality is not supported for directory buckets.</p>
1078 /// </note>
1079 pub fn sse_customer_key(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
1080 self.inner = self.inner.sse_customer_key(input.into());
1081 self
1082 }
1083 /// <p>Specifies the customer-provided encryption key for Amazon S3 to use in encrypting data. This value is used to store the object and then it is discarded; Amazon S3 does not store the encryption key. The key must be appropriate for use with the algorithm specified in the <code>x-amz-server-side-encryption-customer-algorithm</code> header.</p><note>
1084 /// <p>This functionality is not supported for directory buckets.</p>
1085 /// </note>
1086 pub fn set_sse_customer_key(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
1087 self.inner = self.inner.set_sse_customer_key(input);
1088 self
1089 }
1090 /// <p>Specifies the customer-provided encryption key for Amazon S3 to use in encrypting data. This value is used to store the object and then it is discarded; Amazon S3 does not store the encryption key. The key must be appropriate for use with the algorithm specified in the <code>x-amz-server-side-encryption-customer-algorithm</code> header.</p><note>
1091 /// <p>This functionality is not supported for directory buckets.</p>
1092 /// </note>
1093 pub fn get_sse_customer_key(&self) -> &::std::option::Option<::std::string::String> {
1094 self.inner.get_sse_customer_key()
1095 }
1096 /// <p>Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321. Amazon S3 uses this header for a message integrity check to ensure that the encryption key was transmitted without error.</p><note>
1097 /// <p>This functionality is not supported for directory buckets.</p>
1098 /// </note>
1099 pub fn sse_customer_key_md5(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
1100 self.inner = self.inner.sse_customer_key_md5(input.into());
1101 self
1102 }
1103 /// <p>Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321. Amazon S3 uses this header for a message integrity check to ensure that the encryption key was transmitted without error.</p><note>
1104 /// <p>This functionality is not supported for directory buckets.</p>
1105 /// </note>
1106 pub fn set_sse_customer_key_md5(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
1107 self.inner = self.inner.set_sse_customer_key_md5(input);
1108 self
1109 }
1110 /// <p>Specifies the 128-bit MD5 digest of the encryption key according to RFC 1321. Amazon S3 uses this header for a message integrity check to ensure that the encryption key was transmitted without error.</p><note>
1111 /// <p>This functionality is not supported for directory buckets.</p>
1112 /// </note>
1113 pub fn get_sse_customer_key_md5(&self) -> &::std::option::Option<::std::string::String> {
1114 self.inner.get_sse_customer_key_md5()
1115 }
1116 /// <p>Specifies the KMS key ID (Key ID, Key ARN, or Key Alias) to use for object encryption. If the KMS key doesn't exist in the same account that's issuing the command, you must use the full Key ARN not the Key ID.</p>
1117 /// <p><b>General purpose buckets</b> - If you specify <code>x-amz-server-side-encryption</code> with <code>aws:kms</code> or <code>aws:kms:dsse</code>, this header specifies the ID (Key ID, Key ARN, or Key Alias) of the KMS key to use. If you specify <code>x-amz-server-side-encryption:aws:kms</code> or <code>x-amz-server-side-encryption:aws:kms:dsse</code>, but do not provide <code>x-amz-server-side-encryption-aws-kms-key-id</code>, Amazon S3 uses the Amazon Web Services managed key (<code>aws/s3</code>) to protect the data.</p>
1118 /// <p><b>Directory buckets</b> - To encrypt data using SSE-KMS, it's recommended to specify the <code>x-amz-server-side-encryption</code> header to <code>aws:kms</code>. Then, the <code>x-amz-server-side-encryption-aws-kms-key-id</code> header implicitly uses the bucket's default KMS customer managed key ID. If you want to explicitly set the <code> x-amz-server-side-encryption-aws-kms-key-id</code> header, it must match the bucket's default customer managed key (using key ID or ARN, not alias). Your SSE-KMS configuration can only support 1 <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk">customer managed key</a> per directory bucket's lifetime. The <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk">Amazon Web Services managed key</a> (<code>aws/s3</code>) isn't supported. Incorrect key specification results in an HTTP <code>400 Bad Request</code> error.</p>
1119 pub fn ssekms_key_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
1120 self.inner = self.inner.ssekms_key_id(input.into());
1121 self
1122 }
1123 /// <p>Specifies the KMS key ID (Key ID, Key ARN, or Key Alias) to use for object encryption. If the KMS key doesn't exist in the same account that's issuing the command, you must use the full Key ARN not the Key ID.</p>
1124 /// <p><b>General purpose buckets</b> - If you specify <code>x-amz-server-side-encryption</code> with <code>aws:kms</code> or <code>aws:kms:dsse</code>, this header specifies the ID (Key ID, Key ARN, or Key Alias) of the KMS key to use. If you specify <code>x-amz-server-side-encryption:aws:kms</code> or <code>x-amz-server-side-encryption:aws:kms:dsse</code>, but do not provide <code>x-amz-server-side-encryption-aws-kms-key-id</code>, Amazon S3 uses the Amazon Web Services managed key (<code>aws/s3</code>) to protect the data.</p>
1125 /// <p><b>Directory buckets</b> - To encrypt data using SSE-KMS, it's recommended to specify the <code>x-amz-server-side-encryption</code> header to <code>aws:kms</code>. Then, the <code>x-amz-server-side-encryption-aws-kms-key-id</code> header implicitly uses the bucket's default KMS customer managed key ID. If you want to explicitly set the <code> x-amz-server-side-encryption-aws-kms-key-id</code> header, it must match the bucket's default customer managed key (using key ID or ARN, not alias). Your SSE-KMS configuration can only support 1 <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk">customer managed key</a> per directory bucket's lifetime. The <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk">Amazon Web Services managed key</a> (<code>aws/s3</code>) isn't supported. Incorrect key specification results in an HTTP <code>400 Bad Request</code> error.</p>
1126 pub fn set_ssekms_key_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
1127 self.inner = self.inner.set_ssekms_key_id(input);
1128 self
1129 }
1130 /// <p>Specifies the KMS key ID (Key ID, Key ARN, or Key Alias) to use for object encryption. If the KMS key doesn't exist in the same account that's issuing the command, you must use the full Key ARN not the Key ID.</p>
1131 /// <p><b>General purpose buckets</b> - If you specify <code>x-amz-server-side-encryption</code> with <code>aws:kms</code> or <code>aws:kms:dsse</code>, this header specifies the ID (Key ID, Key ARN, or Key Alias) of the KMS key to use. If you specify <code>x-amz-server-side-encryption:aws:kms</code> or <code>x-amz-server-side-encryption:aws:kms:dsse</code>, but do not provide <code>x-amz-server-side-encryption-aws-kms-key-id</code>, Amazon S3 uses the Amazon Web Services managed key (<code>aws/s3</code>) to protect the data.</p>
1132 /// <p><b>Directory buckets</b> - To encrypt data using SSE-KMS, it's recommended to specify the <code>x-amz-server-side-encryption</code> header to <code>aws:kms</code>. Then, the <code>x-amz-server-side-encryption-aws-kms-key-id</code> header implicitly uses the bucket's default KMS customer managed key ID. If you want to explicitly set the <code> x-amz-server-side-encryption-aws-kms-key-id</code> header, it must match the bucket's default customer managed key (using key ID or ARN, not alias). Your SSE-KMS configuration can only support 1 <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#customer-cmk">customer managed key</a> per directory bucket's lifetime. The <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#aws-managed-cmk">Amazon Web Services managed key</a> (<code>aws/s3</code>) isn't supported. Incorrect key specification results in an HTTP <code>400 Bad Request</code> error.</p>
1133 pub fn get_ssekms_key_id(&self) -> &::std::option::Option<::std::string::String> {
1134 self.inner.get_ssekms_key_id()
1135 }
1136 /// <p>Specifies the Amazon Web Services KMS Encryption Context as an additional 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>
1137 /// <p><b>General purpose buckets</b> - This value must be explicitly added during <code>CopyObject</code> operations if you want an additional encryption context for your object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/UsingKMSEncryption.html#encryption-context">Encryption context</a> in the <i>Amazon S3 User Guide</i>.</p>
1138 /// <p><b>Directory buckets</b> - You can optionally provide an explicit encryption context value. The value must match the default encryption context - the bucket Amazon Resource Name (ARN). An additional encryption context value is not supported.</p>
1139 pub fn ssekms_encryption_context(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
1140 self.inner = self.inner.ssekms_encryption_context(input.into());
1141 self
1142 }
1143 /// <p>Specifies the Amazon Web Services KMS Encryption Context as an additional 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>
1144 /// <p><b>General purpose buckets</b> - This value must be explicitly added during <code>CopyObject</code> operations if you want an additional encryption context for your object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/UsingKMSEncryption.html#encryption-context">Encryption context</a> in the <i>Amazon S3 User Guide</i>.</p>
1145 /// <p><b>Directory buckets</b> - You can optionally provide an explicit encryption context value. The value must match the default encryption context - the bucket Amazon Resource Name (ARN). An additional encryption context value is not supported.</p>
1146 pub fn set_ssekms_encryption_context(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
1147 self.inner = self.inner.set_ssekms_encryption_context(input);
1148 self
1149 }
1150 /// <p>Specifies the Amazon Web Services KMS Encryption Context as an additional 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>
1151 /// <p><b>General purpose buckets</b> - This value must be explicitly added during <code>CopyObject</code> operations if you want an additional encryption context for your object. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/UsingKMSEncryption.html#encryption-context">Encryption context</a> in the <i>Amazon S3 User Guide</i>.</p>
1152 /// <p><b>Directory buckets</b> - You can optionally provide an explicit encryption context value. The value must match the default encryption context - the bucket Amazon Resource Name (ARN). An additional encryption context value is not supported.</p>
1153 pub fn get_ssekms_encryption_context(&self) -> &::std::option::Option<::std::string::String> {
1154 self.inner.get_ssekms_encryption_context()
1155 }
1156 /// <p>Specifies whether Amazon S3 should use an S3 Bucket Key for object encryption with server-side encryption using Key Management Service (KMS) keys (SSE-KMS).</p>
1157 /// <p><b>General purpose buckets</b> - Setting this header to <code>true</code> causes Amazon S3 to use an S3 Bucket Key for object encryption with SSE-KMS. Also, specifying this header with a PUT action doesn't affect bucket-level settings for S3 Bucket Key.</p>
1158 /// <p><b>Directory buckets</b> - S3 Bucket Keys are always enabled for <code>GET</code> and <code>PUT</code> operations in a directory bucket and can’t be disabled. S3 Bucket Keys aren't supported, when you copy SSE-KMS encrypted objects from general purpose buckets to directory buckets, from directory buckets to general purpose buckets, or between directory buckets, through <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html">CopyObject</a>, <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html">UploadPartCopy</a>, <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-objects-Batch-Ops">the Copy operation in Batch Operations</a>, or <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/create-import-job">the import jobs</a>. In this case, Amazon S3 makes a call to KMS every time a copy request is made for a KMS-encrypted object.</p>
1159 pub fn bucket_key_enabled(mut self, input: bool) -> Self {
1160 self.inner = self.inner.bucket_key_enabled(input);
1161 self
1162 }
1163 /// <p>Specifies whether Amazon S3 should use an S3 Bucket Key for object encryption with server-side encryption using Key Management Service (KMS) keys (SSE-KMS).</p>
1164 /// <p><b>General purpose buckets</b> - Setting this header to <code>true</code> causes Amazon S3 to use an S3 Bucket Key for object encryption with SSE-KMS. Also, specifying this header with a PUT action doesn't affect bucket-level settings for S3 Bucket Key.</p>
1165 /// <p><b>Directory buckets</b> - S3 Bucket Keys are always enabled for <code>GET</code> and <code>PUT</code> operations in a directory bucket and can’t be disabled. S3 Bucket Keys aren't supported, when you copy SSE-KMS encrypted objects from general purpose buckets to directory buckets, from directory buckets to general purpose buckets, or between directory buckets, through <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html">CopyObject</a>, <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html">UploadPartCopy</a>, <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-objects-Batch-Ops">the Copy operation in Batch Operations</a>, or <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/create-import-job">the import jobs</a>. In this case, Amazon S3 makes a call to KMS every time a copy request is made for a KMS-encrypted object.</p>
1166 pub fn set_bucket_key_enabled(mut self, input: ::std::option::Option<bool>) -> Self {
1167 self.inner = self.inner.set_bucket_key_enabled(input);
1168 self
1169 }
1170 /// <p>Specifies whether Amazon S3 should use an S3 Bucket Key for object encryption with server-side encryption using Key Management Service (KMS) keys (SSE-KMS).</p>
1171 /// <p><b>General purpose buckets</b> - Setting this header to <code>true</code> causes Amazon S3 to use an S3 Bucket Key for object encryption with SSE-KMS. Also, specifying this header with a PUT action doesn't affect bucket-level settings for S3 Bucket Key.</p>
1172 /// <p><b>Directory buckets</b> - S3 Bucket Keys are always enabled for <code>GET</code> and <code>PUT</code> operations in a directory bucket and can’t be disabled. S3 Bucket Keys aren't supported, when you copy SSE-KMS encrypted objects from general purpose buckets to directory buckets, from directory buckets to general purpose buckets, or between directory buckets, through <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html">CopyObject</a>, <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html">UploadPartCopy</a>, <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-objects-Batch-Ops">the Copy operation in Batch Operations</a>, or <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/create-import-job">the import jobs</a>. In this case, Amazon S3 makes a call to KMS every time a copy request is made for a KMS-encrypted object.</p>
1173 pub fn get_bucket_key_enabled(&self) -> &::std::option::Option<bool> {
1174 self.inner.get_bucket_key_enabled()
1175 }
1176 /// <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 the corresponding charges. 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>
1177 /// <p>This functionality is not supported for directory buckets.</p>
1178 /// </note>
1179 pub fn request_payer(mut self, input: crate::types::RequestPayer) -> Self {
1180 self.inner = self.inner.request_payer(input);
1181 self
1182 }
1183 /// <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 the corresponding charges. 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>
1184 /// <p>This functionality is not supported for directory buckets.</p>
1185 /// </note>
1186 pub fn set_request_payer(mut self, input: ::std::option::Option<crate::types::RequestPayer>) -> Self {
1187 self.inner = self.inner.set_request_payer(input);
1188 self
1189 }
1190 /// <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 the corresponding charges. 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>
1191 /// <p>This functionality is not supported for directory buckets.</p>
1192 /// </note>
1193 pub fn get_request_payer(&self) -> &::std::option::Option<crate::types::RequestPayer> {
1194 self.inner.get_request_payer()
1195 }
1196 /// <p>The tag-set for the object. The tag-set must be encoded as URL Query parameters. (For example, "Key1=Value1")</p><note>
1197 /// <p>This functionality is not supported for directory buckets.</p>
1198 /// </note>
1199 pub fn tagging(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
1200 self.inner = self.inner.tagging(input.into());
1201 self
1202 }
1203 /// <p>The tag-set for the object. The tag-set must be encoded as URL Query parameters. (For example, "Key1=Value1")</p><note>
1204 /// <p>This functionality is not supported for directory buckets.</p>
1205 /// </note>
1206 pub fn set_tagging(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
1207 self.inner = self.inner.set_tagging(input);
1208 self
1209 }
1210 /// <p>The tag-set for the object. The tag-set must be encoded as URL Query parameters. (For example, "Key1=Value1")</p><note>
1211 /// <p>This functionality is not supported for directory buckets.</p>
1212 /// </note>
1213 pub fn get_tagging(&self) -> &::std::option::Option<::std::string::String> {
1214 self.inner.get_tagging()
1215 }
1216 /// <p>The Object Lock mode that you want to apply to this object.</p><note>
1217 /// <p>This functionality is not supported for directory buckets.</p>
1218 /// </note>
1219 pub fn object_lock_mode(mut self, input: crate::types::ObjectLockMode) -> Self {
1220 self.inner = self.inner.object_lock_mode(input);
1221 self
1222 }
1223 /// <p>The Object Lock mode that you want to apply to this object.</p><note>
1224 /// <p>This functionality is not supported for directory buckets.</p>
1225 /// </note>
1226 pub fn set_object_lock_mode(mut self, input: ::std::option::Option<crate::types::ObjectLockMode>) -> Self {
1227 self.inner = self.inner.set_object_lock_mode(input);
1228 self
1229 }
1230 /// <p>The Object Lock mode that you want to apply to this object.</p><note>
1231 /// <p>This functionality is not supported for directory buckets.</p>
1232 /// </note>
1233 pub fn get_object_lock_mode(&self) -> &::std::option::Option<crate::types::ObjectLockMode> {
1234 self.inner.get_object_lock_mode()
1235 }
1236 /// <p>The date and time when you want this object's Object Lock to expire. Must be formatted as a timestamp parameter.</p><note>
1237 /// <p>This functionality is not supported for directory buckets.</p>
1238 /// </note>
1239 pub fn object_lock_retain_until_date(mut self, input: ::aws_smithy_types::DateTime) -> Self {
1240 self.inner = self.inner.object_lock_retain_until_date(input);
1241 self
1242 }
1243 /// <p>The date and time when you want this object's Object Lock to expire. Must be formatted as a timestamp parameter.</p><note>
1244 /// <p>This functionality is not supported for directory buckets.</p>
1245 /// </note>
1246 pub fn set_object_lock_retain_until_date(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
1247 self.inner = self.inner.set_object_lock_retain_until_date(input);
1248 self
1249 }
1250 /// <p>The date and time when you want this object's Object Lock to expire. Must be formatted as a timestamp parameter.</p><note>
1251 /// <p>This functionality is not supported for directory buckets.</p>
1252 /// </note>
1253 pub fn get_object_lock_retain_until_date(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
1254 self.inner.get_object_lock_retain_until_date()
1255 }
1256 /// <p>Specifies whether a legal hold will be applied to this object. For more information about S3 Object Lock, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html">Object Lock</a> in the <i>Amazon S3 User Guide</i>.</p><note>
1257 /// <p>This functionality is not supported for directory buckets.</p>
1258 /// </note>
1259 pub fn object_lock_legal_hold_status(mut self, input: crate::types::ObjectLockLegalHoldStatus) -> Self {
1260 self.inner = self.inner.object_lock_legal_hold_status(input);
1261 self
1262 }
1263 /// <p>Specifies whether a legal hold will be applied to this object. For more information about S3 Object Lock, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html">Object Lock</a> in the <i>Amazon S3 User Guide</i>.</p><note>
1264 /// <p>This functionality is not supported for directory buckets.</p>
1265 /// </note>
1266 pub fn set_object_lock_legal_hold_status(mut self, input: ::std::option::Option<crate::types::ObjectLockLegalHoldStatus>) -> Self {
1267 self.inner = self.inner.set_object_lock_legal_hold_status(input);
1268 self
1269 }
1270 /// <p>Specifies whether a legal hold will be applied to this object. For more information about S3 Object Lock, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lock.html">Object Lock</a> in the <i>Amazon S3 User Guide</i>.</p><note>
1271 /// <p>This functionality is not supported for directory buckets.</p>
1272 /// </note>
1273 pub fn get_object_lock_legal_hold_status(&self) -> &::std::option::Option<crate::types::ObjectLockLegalHoldStatus> {
1274 self.inner.get_object_lock_legal_hold_status()
1275 }
1276 /// <p>Specifies the event hold status to apply to this object. Set to <code>ON</code> to enable or <code>OFF</code> to disable.</p><note>
1277 /// <p>This functionality is not supported for directory buckets.</p>
1278 /// </note>
1279 pub fn object_lock_event_hold(mut self, input: crate::types::ObjectLockEventHold) -> Self {
1280 self.inner = self.inner.object_lock_event_hold(input);
1281 self
1282 }
1283 /// <p>Specifies the event hold status to apply to this object. Set to <code>ON</code> to enable or <code>OFF</code> to disable.</p><note>
1284 /// <p>This functionality is not supported for directory buckets.</p>
1285 /// </note>
1286 pub fn set_object_lock_event_hold(mut self, input: ::std::option::Option<crate::types::ObjectLockEventHold>) -> Self {
1287 self.inner = self.inner.set_object_lock_event_hold(input);
1288 self
1289 }
1290 /// <p>Specifies the event hold status to apply to this object. Set to <code>ON</code> to enable or <code>OFF</code> to disable.</p><note>
1291 /// <p>This functionality is not supported for directory buckets.</p>
1292 /// </note>
1293 pub fn get_object_lock_event_hold(&self) -> &::std::option::Option<crate::types::ObjectLockEventHold> {
1294 self.inner.get_object_lock_event_hold()
1295 }
1296 /// <p>Specifies the event hold duration in days to apply to this object. You cannot specify a duration in both days and years.</p><note>
1297 /// <p>This functionality is not supported for directory buckets.</p>
1298 /// </note>
1299 pub fn object_lock_event_hold_duration_days(mut self, input: i32) -> Self {
1300 self.inner = self.inner.object_lock_event_hold_duration_days(input);
1301 self
1302 }
1303 /// <p>Specifies the event hold duration in days to apply to this object. You cannot specify a duration in both days and years.</p><note>
1304 /// <p>This functionality is not supported for directory buckets.</p>
1305 /// </note>
1306 pub fn set_object_lock_event_hold_duration_days(mut self, input: ::std::option::Option<i32>) -> Self {
1307 self.inner = self.inner.set_object_lock_event_hold_duration_days(input);
1308 self
1309 }
1310 /// <p>Specifies the event hold duration in days to apply to this object. You cannot specify a duration in both days and years.</p><note>
1311 /// <p>This functionality is not supported for directory buckets.</p>
1312 /// </note>
1313 pub fn get_object_lock_event_hold_duration_days(&self) -> &::std::option::Option<i32> {
1314 self.inner.get_object_lock_event_hold_duration_days()
1315 }
1316 /// <p>Specifies the event hold duration in years to apply to this object. You cannot specify a duration in both days and years.</p><note>
1317 /// <p>This functionality is not supported for directory buckets.</p>
1318 /// </note>
1319 pub fn object_lock_event_hold_duration_years(mut self, input: i32) -> Self {
1320 self.inner = self.inner.object_lock_event_hold_duration_years(input);
1321 self
1322 }
1323 /// <p>Specifies the event hold duration in years to apply to this object. You cannot specify a duration in both days and years.</p><note>
1324 /// <p>This functionality is not supported for directory buckets.</p>
1325 /// </note>
1326 pub fn set_object_lock_event_hold_duration_years(mut self, input: ::std::option::Option<i32>) -> Self {
1327 self.inner = self.inner.set_object_lock_event_hold_duration_years(input);
1328 self
1329 }
1330 /// <p>Specifies the event hold duration in years to apply to this object. You cannot specify a duration in both days and years.</p><note>
1331 /// <p>This functionality is not supported for directory buckets.</p>
1332 /// </note>
1333 pub fn get_object_lock_event_hold_duration_years(&self) -> &::std::option::Option<i32> {
1334 self.inner.get_object_lock_event_hold_duration_years()
1335 }
1336 /// <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>
1337 pub fn expected_bucket_owner(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
1338 self.inner = self.inner.expected_bucket_owner(input.into());
1339 self
1340 }
1341 /// <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>
1342 pub fn set_expected_bucket_owner(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
1343 self.inner = self.inner.set_expected_bucket_owner(input);
1344 self
1345 }
1346 /// <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>
1347 pub fn get_expected_bucket_owner(&self) -> &::std::option::Option<::std::string::String> {
1348 self.inner.get_expected_bucket_owner()
1349 }
1350}
1351
1352impl crate::client::customize::internal::CustomizablePresigned<crate::operation::put_object::PutObjectError> for PutObjectFluentBuilder {
1353 fn presign(
1354 self,
1355 config_override: crate::config::Builder,
1356 presigning_config: crate::presigning::PresigningConfig,
1357 ) -> crate::client::customize::internal::BoxFuture<
1358 crate::client::customize::internal::SendResult<crate::presigning::PresignedRequest, crate::operation::put_object::PutObjectError>,
1359 > {
1360 ::std::boxed::Box::pin(async move { self.config_override(config_override).presigned(presigning_config).await })
1361 }
1362}