aws_sdk_s3/operation/list_objects/
_list_objects_output.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2#[allow(missing_docs)] // documentation missing in model
3#[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct ListObjectsOutput {
6    /// <p>A flag that indicates whether Amazon S3 returned all of the results that satisfied the search criteria.</p>
7    pub is_truncated: ::std::option::Option<bool>,
8    /// <p>Indicates where in the bucket listing begins. Marker is included in the response if it was sent with the request.</p>
9    pub marker: ::std::option::Option<::std::string::String>,
10    /// <p>When the response is truncated (the <code>IsTruncated</code> element value in the response is <code>true</code>), you can use the key name in this field as the <code>marker</code> parameter in the subsequent request to get the next set of objects. Amazon S3 lists objects in alphabetical order.</p><note>
11    /// <p>This element is returned only if you have the <code>delimiter</code> request parameter specified. If the response does not include the <code>NextMarker</code> element and it is truncated, you can use the value of the last <code>Key</code> element in the response as the <code>marker</code> parameter in the subsequent request to get the next set of object keys.</p>
12    /// </note>
13    pub next_marker: ::std::option::Option<::std::string::String>,
14    /// <p>Metadata about each object returned.</p>
15    pub contents: ::std::option::Option<::std::vec::Vec<crate::types::Object>>,
16    /// <p>The bucket name.</p>
17    pub name: ::std::option::Option<::std::string::String>,
18    /// <p>Keys that begin with the indicated prefix.</p>
19    pub prefix: ::std::option::Option<::std::string::String>,
20    /// <p>Causes keys that contain the same string between the prefix and the first occurrence of the delimiter to be rolled up into a single result element in the <code>CommonPrefixes</code> collection. These rolled-up keys are not returned elsewhere in the response. Each rolled-up result counts as only one return against the <code>MaxKeys</code> value.</p>
21    pub delimiter: ::std::option::Option<::std::string::String>,
22    /// <p>The maximum number of keys returned in the response body.</p>
23    pub max_keys: ::std::option::Option<i32>,
24    /// <p>All of the keys (up to 1,000) rolled up in a common prefix count as a single return when calculating the number of returns.</p>
25    /// <p>A response can contain <code>CommonPrefixes</code> only if you specify a delimiter.</p>
26    /// <p><code>CommonPrefixes</code> contains all (if there are any) keys between <code>Prefix</code> and the next occurrence of the string specified by the delimiter.</p>
27    /// <p><code>CommonPrefixes</code> lists keys that act like subdirectories in the directory specified by <code>Prefix</code>.</p>
28    /// <p>For example, if the prefix is <code>notes/</code> and the delimiter is a slash (<code>/</code>), as in <code>notes/summer/july</code>, the common prefix is <code>notes/summer/</code>. All of the keys that roll up into a common prefix count as a single return when calculating the number of returns.</p>
29    pub common_prefixes: ::std::option::Option<::std::vec::Vec<crate::types::CommonPrefix>>,
30    /// <p>Encoding type used by Amazon S3 to encode the <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html">object keys</a> in the response. Responses are encoded only in UTF-8. An object key can contain any Unicode character. However, the XML 1.0 parser can't parse certain characters, such as characters with an ASCII value from 0 to 10. For characters that aren't supported in XML 1.0, you can add this parameter to request that Amazon S3 encode the keys in the response. For more information about characters to avoid in object key names, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-guidelines">Object key naming guidelines</a>.</p><note>
31    /// <p>When using the URL encoding type, non-ASCII characters that are used in an object's key name will be percent-encoded according to UTF-8 code values. For example, the object <code>test_file(3).png</code> will appear as <code>test_file%283%29.png</code>.</p>
32    /// </note>
33    pub encoding_type: ::std::option::Option<crate::types::EncodingType>,
34    /// <p>If present, indicates that the requester was successfully charged for the request.</p><note>
35    /// <p>This functionality is not supported for directory buckets.</p>
36    /// </note>
37    pub request_charged: ::std::option::Option<crate::types::RequestCharged>,
38    _extended_request_id: Option<String>,
39    _request_id: Option<String>,
40}
41impl ListObjectsOutput {
42    /// <p>A flag that indicates whether Amazon S3 returned all of the results that satisfied the search criteria.</p>
43    pub fn is_truncated(&self) -> ::std::option::Option<bool> {
44        self.is_truncated
45    }
46    /// <p>Indicates where in the bucket listing begins. Marker is included in the response if it was sent with the request.</p>
47    pub fn marker(&self) -> ::std::option::Option<&str> {
48        self.marker.as_deref()
49    }
50    /// <p>When the response is truncated (the <code>IsTruncated</code> element value in the response is <code>true</code>), you can use the key name in this field as the <code>marker</code> parameter in the subsequent request to get the next set of objects. Amazon S3 lists objects in alphabetical order.</p><note>
51    /// <p>This element is returned only if you have the <code>delimiter</code> request parameter specified. If the response does not include the <code>NextMarker</code> element and it is truncated, you can use the value of the last <code>Key</code> element in the response as the <code>marker</code> parameter in the subsequent request to get the next set of object keys.</p>
52    /// </note>
53    pub fn next_marker(&self) -> ::std::option::Option<&str> {
54        self.next_marker.as_deref()
55    }
56    /// <p>Metadata about each object returned.</p>
57    ///
58    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.contents.is_none()`.
59    pub fn contents(&self) -> &[crate::types::Object] {
60        self.contents.as_deref().unwrap_or_default()
61    }
62    /// <p>The bucket name.</p>
63    pub fn name(&self) -> ::std::option::Option<&str> {
64        self.name.as_deref()
65    }
66    /// <p>Keys that begin with the indicated prefix.</p>
67    pub fn prefix(&self) -> ::std::option::Option<&str> {
68        self.prefix.as_deref()
69    }
70    /// <p>Causes keys that contain the same string between the prefix and the first occurrence of the delimiter to be rolled up into a single result element in the <code>CommonPrefixes</code> collection. These rolled-up keys are not returned elsewhere in the response. Each rolled-up result counts as only one return against the <code>MaxKeys</code> value.</p>
71    pub fn delimiter(&self) -> ::std::option::Option<&str> {
72        self.delimiter.as_deref()
73    }
74    /// <p>The maximum number of keys returned in the response body.</p>
75    pub fn max_keys(&self) -> ::std::option::Option<i32> {
76        self.max_keys
77    }
78    /// <p>All of the keys (up to 1,000) rolled up in a common prefix count as a single return when calculating the number of returns.</p>
79    /// <p>A response can contain <code>CommonPrefixes</code> only if you specify a delimiter.</p>
80    /// <p><code>CommonPrefixes</code> contains all (if there are any) keys between <code>Prefix</code> and the next occurrence of the string specified by the delimiter.</p>
81    /// <p><code>CommonPrefixes</code> lists keys that act like subdirectories in the directory specified by <code>Prefix</code>.</p>
82    /// <p>For example, if the prefix is <code>notes/</code> and the delimiter is a slash (<code>/</code>), as in <code>notes/summer/july</code>, the common prefix is <code>notes/summer/</code>. All of the keys that roll up into a common prefix count as a single return when calculating the number of returns.</p>
83    ///
84    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.common_prefixes.is_none()`.
85    pub fn common_prefixes(&self) -> &[crate::types::CommonPrefix] {
86        self.common_prefixes.as_deref().unwrap_or_default()
87    }
88    /// <p>Encoding type used by Amazon S3 to encode the <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html">object keys</a> in the response. Responses are encoded only in UTF-8. An object key can contain any Unicode character. However, the XML 1.0 parser can't parse certain characters, such as characters with an ASCII value from 0 to 10. For characters that aren't supported in XML 1.0, you can add this parameter to request that Amazon S3 encode the keys in the response. For more information about characters to avoid in object key names, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-guidelines">Object key naming guidelines</a>.</p><note>
89    /// <p>When using the URL encoding type, non-ASCII characters that are used in an object's key name will be percent-encoded according to UTF-8 code values. For example, the object <code>test_file(3).png</code> will appear as <code>test_file%283%29.png</code>.</p>
90    /// </note>
91    pub fn encoding_type(&self) -> ::std::option::Option<&crate::types::EncodingType> {
92        self.encoding_type.as_ref()
93    }
94    /// <p>If present, indicates that the requester was successfully charged for the request.</p><note>
95    /// <p>This functionality is not supported for directory buckets.</p>
96    /// </note>
97    pub fn request_charged(&self) -> ::std::option::Option<&crate::types::RequestCharged> {
98        self.request_charged.as_ref()
99    }
100}
101impl crate::s3_request_id::RequestIdExt for ListObjectsOutput {
102    fn extended_request_id(&self) -> Option<&str> {
103        self._extended_request_id.as_deref()
104    }
105}
106impl ::aws_types::request_id::RequestId for ListObjectsOutput {
107    fn request_id(&self) -> Option<&str> {
108        self._request_id.as_deref()
109    }
110}
111impl ListObjectsOutput {
112    /// Creates a new builder-style object to manufacture [`ListObjectsOutput`](crate::operation::list_objects::ListObjectsOutput).
113    pub fn builder() -> crate::operation::list_objects::builders::ListObjectsOutputBuilder {
114        crate::operation::list_objects::builders::ListObjectsOutputBuilder::default()
115    }
116}
117
118/// A builder for [`ListObjectsOutput`](crate::operation::list_objects::ListObjectsOutput).
119#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
120#[non_exhaustive]
121pub struct ListObjectsOutputBuilder {
122    pub(crate) is_truncated: ::std::option::Option<bool>,
123    pub(crate) marker: ::std::option::Option<::std::string::String>,
124    pub(crate) next_marker: ::std::option::Option<::std::string::String>,
125    pub(crate) contents: ::std::option::Option<::std::vec::Vec<crate::types::Object>>,
126    pub(crate) name: ::std::option::Option<::std::string::String>,
127    pub(crate) prefix: ::std::option::Option<::std::string::String>,
128    pub(crate) delimiter: ::std::option::Option<::std::string::String>,
129    pub(crate) max_keys: ::std::option::Option<i32>,
130    pub(crate) common_prefixes: ::std::option::Option<::std::vec::Vec<crate::types::CommonPrefix>>,
131    pub(crate) encoding_type: ::std::option::Option<crate::types::EncodingType>,
132    pub(crate) request_charged: ::std::option::Option<crate::types::RequestCharged>,
133    _extended_request_id: Option<String>,
134    _request_id: Option<String>,
135}
136impl ListObjectsOutputBuilder {
137    /// <p>A flag that indicates whether Amazon S3 returned all of the results that satisfied the search criteria.</p>
138    pub fn is_truncated(mut self, input: bool) -> Self {
139        self.is_truncated = ::std::option::Option::Some(input);
140        self
141    }
142    /// <p>A flag that indicates whether Amazon S3 returned all of the results that satisfied the search criteria.</p>
143    pub fn set_is_truncated(mut self, input: ::std::option::Option<bool>) -> Self {
144        self.is_truncated = input;
145        self
146    }
147    /// <p>A flag that indicates whether Amazon S3 returned all of the results that satisfied the search criteria.</p>
148    pub fn get_is_truncated(&self) -> &::std::option::Option<bool> {
149        &self.is_truncated
150    }
151    /// <p>Indicates where in the bucket listing begins. Marker is included in the response if it was sent with the request.</p>
152    pub fn marker(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
153        self.marker = ::std::option::Option::Some(input.into());
154        self
155    }
156    /// <p>Indicates where in the bucket listing begins. Marker is included in the response if it was sent with the request.</p>
157    pub fn set_marker(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
158        self.marker = input;
159        self
160    }
161    /// <p>Indicates where in the bucket listing begins. Marker is included in the response if it was sent with the request.</p>
162    pub fn get_marker(&self) -> &::std::option::Option<::std::string::String> {
163        &self.marker
164    }
165    /// <p>When the response is truncated (the <code>IsTruncated</code> element value in the response is <code>true</code>), you can use the key name in this field as the <code>marker</code> parameter in the subsequent request to get the next set of objects. Amazon S3 lists objects in alphabetical order.</p><note>
166    /// <p>This element is returned only if you have the <code>delimiter</code> request parameter specified. If the response does not include the <code>NextMarker</code> element and it is truncated, you can use the value of the last <code>Key</code> element in the response as the <code>marker</code> parameter in the subsequent request to get the next set of object keys.</p>
167    /// </note>
168    pub fn next_marker(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
169        self.next_marker = ::std::option::Option::Some(input.into());
170        self
171    }
172    /// <p>When the response is truncated (the <code>IsTruncated</code> element value in the response is <code>true</code>), you can use the key name in this field as the <code>marker</code> parameter in the subsequent request to get the next set of objects. Amazon S3 lists objects in alphabetical order.</p><note>
173    /// <p>This element is returned only if you have the <code>delimiter</code> request parameter specified. If the response does not include the <code>NextMarker</code> element and it is truncated, you can use the value of the last <code>Key</code> element in the response as the <code>marker</code> parameter in the subsequent request to get the next set of object keys.</p>
174    /// </note>
175    pub fn set_next_marker(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
176        self.next_marker = input;
177        self
178    }
179    /// <p>When the response is truncated (the <code>IsTruncated</code> element value in the response is <code>true</code>), you can use the key name in this field as the <code>marker</code> parameter in the subsequent request to get the next set of objects. Amazon S3 lists objects in alphabetical order.</p><note>
180    /// <p>This element is returned only if you have the <code>delimiter</code> request parameter specified. If the response does not include the <code>NextMarker</code> element and it is truncated, you can use the value of the last <code>Key</code> element in the response as the <code>marker</code> parameter in the subsequent request to get the next set of object keys.</p>
181    /// </note>
182    pub fn get_next_marker(&self) -> &::std::option::Option<::std::string::String> {
183        &self.next_marker
184    }
185    /// Appends an item to `contents`.
186    ///
187    /// To override the contents of this collection use [`set_contents`](Self::set_contents).
188    ///
189    /// <p>Metadata about each object returned.</p>
190    pub fn contents(mut self, input: crate::types::Object) -> Self {
191        let mut v = self.contents.unwrap_or_default();
192        v.push(input);
193        self.contents = ::std::option::Option::Some(v);
194        self
195    }
196    /// <p>Metadata about each object returned.</p>
197    pub fn set_contents(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Object>>) -> Self {
198        self.contents = input;
199        self
200    }
201    /// <p>Metadata about each object returned.</p>
202    pub fn get_contents(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Object>> {
203        &self.contents
204    }
205    /// <p>The bucket name.</p>
206    pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
207        self.name = ::std::option::Option::Some(input.into());
208        self
209    }
210    /// <p>The bucket name.</p>
211    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
212        self.name = input;
213        self
214    }
215    /// <p>The bucket name.</p>
216    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
217        &self.name
218    }
219    /// <p>Keys that begin with the indicated prefix.</p>
220    pub fn prefix(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
221        self.prefix = ::std::option::Option::Some(input.into());
222        self
223    }
224    /// <p>Keys that begin with the indicated prefix.</p>
225    pub fn set_prefix(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
226        self.prefix = input;
227        self
228    }
229    /// <p>Keys that begin with the indicated prefix.</p>
230    pub fn get_prefix(&self) -> &::std::option::Option<::std::string::String> {
231        &self.prefix
232    }
233    /// <p>Causes keys that contain the same string between the prefix and the first occurrence of the delimiter to be rolled up into a single result element in the <code>CommonPrefixes</code> collection. These rolled-up keys are not returned elsewhere in the response. Each rolled-up result counts as only one return against the <code>MaxKeys</code> value.</p>
234    pub fn delimiter(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
235        self.delimiter = ::std::option::Option::Some(input.into());
236        self
237    }
238    /// <p>Causes keys that contain the same string between the prefix and the first occurrence of the delimiter to be rolled up into a single result element in the <code>CommonPrefixes</code> collection. These rolled-up keys are not returned elsewhere in the response. Each rolled-up result counts as only one return against the <code>MaxKeys</code> value.</p>
239    pub fn set_delimiter(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
240        self.delimiter = input;
241        self
242    }
243    /// <p>Causes keys that contain the same string between the prefix and the first occurrence of the delimiter to be rolled up into a single result element in the <code>CommonPrefixes</code> collection. These rolled-up keys are not returned elsewhere in the response. Each rolled-up result counts as only one return against the <code>MaxKeys</code> value.</p>
244    pub fn get_delimiter(&self) -> &::std::option::Option<::std::string::String> {
245        &self.delimiter
246    }
247    /// <p>The maximum number of keys returned in the response body.</p>
248    pub fn max_keys(mut self, input: i32) -> Self {
249        self.max_keys = ::std::option::Option::Some(input);
250        self
251    }
252    /// <p>The maximum number of keys returned in the response body.</p>
253    pub fn set_max_keys(mut self, input: ::std::option::Option<i32>) -> Self {
254        self.max_keys = input;
255        self
256    }
257    /// <p>The maximum number of keys returned in the response body.</p>
258    pub fn get_max_keys(&self) -> &::std::option::Option<i32> {
259        &self.max_keys
260    }
261    /// Appends an item to `common_prefixes`.
262    ///
263    /// To override the contents of this collection use [`set_common_prefixes`](Self::set_common_prefixes).
264    ///
265    /// <p>All of the keys (up to 1,000) rolled up in a common prefix count as a single return when calculating the number of returns.</p>
266    /// <p>A response can contain <code>CommonPrefixes</code> only if you specify a delimiter.</p>
267    /// <p><code>CommonPrefixes</code> contains all (if there are any) keys between <code>Prefix</code> and the next occurrence of the string specified by the delimiter.</p>
268    /// <p><code>CommonPrefixes</code> lists keys that act like subdirectories in the directory specified by <code>Prefix</code>.</p>
269    /// <p>For example, if the prefix is <code>notes/</code> and the delimiter is a slash (<code>/</code>), as in <code>notes/summer/july</code>, the common prefix is <code>notes/summer/</code>. All of the keys that roll up into a common prefix count as a single return when calculating the number of returns.</p>
270    pub fn common_prefixes(mut self, input: crate::types::CommonPrefix) -> Self {
271        let mut v = self.common_prefixes.unwrap_or_default();
272        v.push(input);
273        self.common_prefixes = ::std::option::Option::Some(v);
274        self
275    }
276    /// <p>All of the keys (up to 1,000) rolled up in a common prefix count as a single return when calculating the number of returns.</p>
277    /// <p>A response can contain <code>CommonPrefixes</code> only if you specify a delimiter.</p>
278    /// <p><code>CommonPrefixes</code> contains all (if there are any) keys between <code>Prefix</code> and the next occurrence of the string specified by the delimiter.</p>
279    /// <p><code>CommonPrefixes</code> lists keys that act like subdirectories in the directory specified by <code>Prefix</code>.</p>
280    /// <p>For example, if the prefix is <code>notes/</code> and the delimiter is a slash (<code>/</code>), as in <code>notes/summer/july</code>, the common prefix is <code>notes/summer/</code>. All of the keys that roll up into a common prefix count as a single return when calculating the number of returns.</p>
281    pub fn set_common_prefixes(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::CommonPrefix>>) -> Self {
282        self.common_prefixes = input;
283        self
284    }
285    /// <p>All of the keys (up to 1,000) rolled up in a common prefix count as a single return when calculating the number of returns.</p>
286    /// <p>A response can contain <code>CommonPrefixes</code> only if you specify a delimiter.</p>
287    /// <p><code>CommonPrefixes</code> contains all (if there are any) keys between <code>Prefix</code> and the next occurrence of the string specified by the delimiter.</p>
288    /// <p><code>CommonPrefixes</code> lists keys that act like subdirectories in the directory specified by <code>Prefix</code>.</p>
289    /// <p>For example, if the prefix is <code>notes/</code> and the delimiter is a slash (<code>/</code>), as in <code>notes/summer/july</code>, the common prefix is <code>notes/summer/</code>. All of the keys that roll up into a common prefix count as a single return when calculating the number of returns.</p>
290    pub fn get_common_prefixes(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::CommonPrefix>> {
291        &self.common_prefixes
292    }
293    /// <p>Encoding type used by Amazon S3 to encode the <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html">object keys</a> in the response. Responses are encoded only in UTF-8. An object key can contain any Unicode character. However, the XML 1.0 parser can't parse certain characters, such as characters with an ASCII value from 0 to 10. For characters that aren't supported in XML 1.0, you can add this parameter to request that Amazon S3 encode the keys in the response. For more information about characters to avoid in object key names, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-guidelines">Object key naming guidelines</a>.</p><note>
294    /// <p>When using the URL encoding type, non-ASCII characters that are used in an object's key name will be percent-encoded according to UTF-8 code values. For example, the object <code>test_file(3).png</code> will appear as <code>test_file%283%29.png</code>.</p>
295    /// </note>
296    pub fn encoding_type(mut self, input: crate::types::EncodingType) -> Self {
297        self.encoding_type = ::std::option::Option::Some(input);
298        self
299    }
300    /// <p>Encoding type used by Amazon S3 to encode the <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html">object keys</a> in the response. Responses are encoded only in UTF-8. An object key can contain any Unicode character. However, the XML 1.0 parser can't parse certain characters, such as characters with an ASCII value from 0 to 10. For characters that aren't supported in XML 1.0, you can add this parameter to request that Amazon S3 encode the keys in the response. For more information about characters to avoid in object key names, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-guidelines">Object key naming guidelines</a>.</p><note>
301    /// <p>When using the URL encoding type, non-ASCII characters that are used in an object's key name will be percent-encoded according to UTF-8 code values. For example, the object <code>test_file(3).png</code> will appear as <code>test_file%283%29.png</code>.</p>
302    /// </note>
303    pub fn set_encoding_type(mut self, input: ::std::option::Option<crate::types::EncodingType>) -> Self {
304        self.encoding_type = input;
305        self
306    }
307    /// <p>Encoding type used by Amazon S3 to encode the <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html">object keys</a> in the response. Responses are encoded only in UTF-8. An object key can contain any Unicode character. However, the XML 1.0 parser can't parse certain characters, such as characters with an ASCII value from 0 to 10. For characters that aren't supported in XML 1.0, you can add this parameter to request that Amazon S3 encode the keys in the response. For more information about characters to avoid in object key names, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-guidelines">Object key naming guidelines</a>.</p><note>
308    /// <p>When using the URL encoding type, non-ASCII characters that are used in an object's key name will be percent-encoded according to UTF-8 code values. For example, the object <code>test_file(3).png</code> will appear as <code>test_file%283%29.png</code>.</p>
309    /// </note>
310    pub fn get_encoding_type(&self) -> &::std::option::Option<crate::types::EncodingType> {
311        &self.encoding_type
312    }
313    /// <p>If present, indicates that the requester was successfully charged for the request.</p><note>
314    /// <p>This functionality is not supported for directory buckets.</p>
315    /// </note>
316    pub fn request_charged(mut self, input: crate::types::RequestCharged) -> Self {
317        self.request_charged = ::std::option::Option::Some(input);
318        self
319    }
320    /// <p>If present, indicates that the requester was successfully charged for the request.</p><note>
321    /// <p>This functionality is not supported for directory buckets.</p>
322    /// </note>
323    pub fn set_request_charged(mut self, input: ::std::option::Option<crate::types::RequestCharged>) -> Self {
324        self.request_charged = input;
325        self
326    }
327    /// <p>If present, indicates that the requester was successfully charged for the request.</p><note>
328    /// <p>This functionality is not supported for directory buckets.</p>
329    /// </note>
330    pub fn get_request_charged(&self) -> &::std::option::Option<crate::types::RequestCharged> {
331        &self.request_charged
332    }
333    pub(crate) fn _extended_request_id(mut self, extended_request_id: impl Into<String>) -> Self {
334        self._extended_request_id = Some(extended_request_id.into());
335        self
336    }
337
338    pub(crate) fn _set_extended_request_id(&mut self, extended_request_id: Option<String>) -> &mut Self {
339        self._extended_request_id = extended_request_id;
340        self
341    }
342    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
343        self._request_id = Some(request_id.into());
344        self
345    }
346
347    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
348        self._request_id = request_id;
349        self
350    }
351    /// Consumes the builder and constructs a [`ListObjectsOutput`](crate::operation::list_objects::ListObjectsOutput).
352    pub fn build(self) -> crate::operation::list_objects::ListObjectsOutput {
353        crate::operation::list_objects::ListObjectsOutput {
354            is_truncated: self.is_truncated,
355            marker: self.marker,
356            next_marker: self.next_marker,
357            contents: self.contents,
358            name: self.name,
359            prefix: self.prefix,
360            delimiter: self.delimiter,
361            max_keys: self.max_keys,
362            common_prefixes: self.common_prefixes,
363            encoding_type: self.encoding_type,
364            request_charged: self.request_charged,
365            _extended_request_id: self._extended_request_id,
366            _request_id: self._request_id,
367        }
368    }
369}