AWS SDK for C++

AWS SDK for C++ Version 1.11.781

Loading...
Searching...
No Matches
ListObjectsResult.h
1
6#pragma once
7#include <aws/core/http/HttpResponse.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/s3-crt/S3Crt_EXPORTS.h>
11#include <aws/s3-crt/model/CommonPrefix.h>
12#include <aws/s3-crt/model/EncodingType.h>
13#include <aws/s3-crt/model/Object.h>
14#include <aws/s3-crt/model/RequestCharged.h>
15
16#include <utility>
17
18namespace Aws {
19template <typename RESULT_TYPE>
20class AmazonWebServiceResult;
21
22namespace Utils {
23namespace Xml {
24class XmlDocument;
25} // namespace Xml
26} // namespace Utils
27namespace S3Crt {
28namespace Model {
30 public:
31 AWS_S3CRT_API ListObjectsResult() = default;
34
36
40 inline bool GetIsTruncated() const { return m_isTruncated; }
41 inline void SetIsTruncated(bool value) {
42 m_isTruncatedHasBeenSet = true;
43 m_isTruncated = value;
44 }
45 inline ListObjectsResult& WithIsTruncated(bool value) {
46 SetIsTruncated(value);
47 return *this;
48 }
50
52
56 inline const Aws::String& GetMarker() const { return m_marker; }
57 template <typename MarkerT = Aws::String>
58 void SetMarker(MarkerT&& value) {
59 m_markerHasBeenSet = true;
60 m_marker = std::forward<MarkerT>(value);
61 }
62 template <typename MarkerT = Aws::String>
63 ListObjectsResult& WithMarker(MarkerT&& value) {
64 SetMarker(std::forward<MarkerT>(value));
65 return *this;
66 }
68
70
82 inline const Aws::String& GetNextMarker() const { return m_nextMarker; }
83 template <typename NextMarkerT = Aws::String>
84 void SetNextMarker(NextMarkerT&& value) {
85 m_nextMarkerHasBeenSet = true;
86 m_nextMarker = std::forward<NextMarkerT>(value);
87 }
88 template <typename NextMarkerT = Aws::String>
89 ListObjectsResult& WithNextMarker(NextMarkerT&& value) {
90 SetNextMarker(std::forward<NextMarkerT>(value));
91 return *this;
92 }
94
96
99 inline const Aws::Vector<Object>& GetContents() const { return m_contents; }
100 template <typename ContentsT = Aws::Vector<Object>>
101 void SetContents(ContentsT&& value) {
102 m_contentsHasBeenSet = true;
103 m_contents = std::forward<ContentsT>(value);
104 }
105 template <typename ContentsT = Aws::Vector<Object>>
106 ListObjectsResult& WithContents(ContentsT&& value) {
107 SetContents(std::forward<ContentsT>(value));
108 return *this;
109 }
110 template <typename ContentsT = Object>
111 ListObjectsResult& AddContents(ContentsT&& value) {
112 m_contentsHasBeenSet = true;
113 m_contents.emplace_back(std::forward<ContentsT>(value));
114 return *this;
115 }
117
119
122 inline const Aws::String& GetName() const { return m_name; }
123 template <typename NameT = Aws::String>
124 void SetName(NameT&& value) {
125 m_nameHasBeenSet = true;
126 m_name = std::forward<NameT>(value);
127 }
128 template <typename NameT = Aws::String>
129 ListObjectsResult& WithName(NameT&& value) {
130 SetName(std::forward<NameT>(value));
131 return *this;
132 }
134
136
139 inline const Aws::String& GetPrefix() const { return m_prefix; }
140 template <typename PrefixT = Aws::String>
141 void SetPrefix(PrefixT&& value) {
142 m_prefixHasBeenSet = true;
143 m_prefix = std::forward<PrefixT>(value);
144 }
145 template <typename PrefixT = Aws::String>
146 ListObjectsResult& WithPrefix(PrefixT&& value) {
147 SetPrefix(std::forward<PrefixT>(value));
148 return *this;
149 }
151
153
160 inline const Aws::String& GetDelimiter() const { return m_delimiter; }
161 template <typename DelimiterT = Aws::String>
162 void SetDelimiter(DelimiterT&& value) {
163 m_delimiterHasBeenSet = true;
164 m_delimiter = std::forward<DelimiterT>(value);
165 }
166 template <typename DelimiterT = Aws::String>
167 ListObjectsResult& WithDelimiter(DelimiterT&& value) {
168 SetDelimiter(std::forward<DelimiterT>(value));
169 return *this;
170 }
172
174
177 inline int GetMaxKeys() const { return m_maxKeys; }
178 inline void SetMaxKeys(int value) {
179 m_maxKeysHasBeenSet = true;
180 m_maxKeys = value;
181 }
182 inline ListObjectsResult& WithMaxKeys(int value) {
183 SetMaxKeys(value);
184 return *this;
185 }
187
189
202 inline const Aws::Vector<CommonPrefix>& GetCommonPrefixes() const { return m_commonPrefixes; }
203 template <typename CommonPrefixesT = Aws::Vector<CommonPrefix>>
204 void SetCommonPrefixes(CommonPrefixesT&& value) {
205 m_commonPrefixesHasBeenSet = true;
206 m_commonPrefixes = std::forward<CommonPrefixesT>(value);
207 }
208 template <typename CommonPrefixesT = Aws::Vector<CommonPrefix>>
209 ListObjectsResult& WithCommonPrefixes(CommonPrefixesT&& value) {
210 SetCommonPrefixes(std::forward<CommonPrefixesT>(value));
211 return *this;
212 }
213 template <typename CommonPrefixesT = CommonPrefix>
214 ListObjectsResult& AddCommonPrefixes(CommonPrefixesT&& value) {
215 m_commonPrefixesHasBeenSet = true;
216 m_commonPrefixes.emplace_back(std::forward<CommonPrefixesT>(value));
217 return *this;
218 }
220
222
238 inline EncodingType GetEncodingType() const { return m_encodingType; }
239 inline void SetEncodingType(EncodingType value) {
240 m_encodingTypeHasBeenSet = true;
241 m_encodingType = value;
242 }
244 SetEncodingType(value);
245 return *this;
246 }
248
250
251 inline RequestCharged GetRequestCharged() const { return m_requestCharged; }
253 m_requestChargedHasBeenSet = true;
254 m_requestCharged = value;
255 }
257 SetRequestCharged(value);
258 return *this;
259 }
261
263
264 inline const Aws::String& GetRequestId() const { return m_requestId; }
265 template <typename RequestIdT = Aws::String>
266 void SetRequestId(RequestIdT&& value) {
267 m_requestIdHasBeenSet = true;
268 m_requestId = std::forward<RequestIdT>(value);
269 }
270 template <typename RequestIdT = Aws::String>
271 ListObjectsResult& WithRequestId(RequestIdT&& value) {
272 SetRequestId(std::forward<RequestIdT>(value));
273 return *this;
274 }
276 inline Aws::Http::HttpResponseCode GetHttpResponseCode() const { return m_HttpResponseCode; }
277
278 private:
279 bool m_isTruncated{false};
280
281 Aws::String m_marker;
282
283 Aws::String m_nextMarker;
284
285 Aws::Vector<Object> m_contents;
286
287 Aws::String m_name;
288
289 Aws::String m_prefix;
290
291 Aws::String m_delimiter;
292
293 int m_maxKeys{0};
294
295 Aws::Vector<CommonPrefix> m_commonPrefixes;
296
297 EncodingType m_encodingType{EncodingType::NOT_SET};
298
299 RequestCharged m_requestCharged{RequestCharged::NOT_SET};
300
301 Aws::String m_requestId;
302 Aws::Http::HttpResponseCode m_HttpResponseCode;
303 bool m_isTruncatedHasBeenSet = false;
304 bool m_markerHasBeenSet = false;
305 bool m_nextMarkerHasBeenSet = false;
306 bool m_contentsHasBeenSet = false;
307 bool m_nameHasBeenSet = false;
308 bool m_prefixHasBeenSet = false;
309 bool m_delimiterHasBeenSet = false;
310 bool m_maxKeysHasBeenSet = false;
311 bool m_commonPrefixesHasBeenSet = false;
312 bool m_encodingTypeHasBeenSet = false;
313 bool m_requestChargedHasBeenSet = false;
314 bool m_requestIdHasBeenSet = false;
315};
316
317} // namespace Model
318} // namespace S3Crt
319} // namespace Aws
const Aws::String & GetMarker() const
ListObjectsResult & WithMarker(MarkerT &&value)
ListObjectsResult & WithName(NameT &&value)
ListObjectsResult & WithEncodingType(EncodingType value)
void SetCommonPrefixes(CommonPrefixesT &&value)
ListObjectsResult & WithMaxKeys(int value)
const Aws::String & GetNextMarker() const
const Aws::String & GetName() const
const Aws::Vector< CommonPrefix > & GetCommonPrefixes() const
void SetEncodingType(EncodingType value)
AWS_S3CRT_API ListObjectsResult()=default
ListObjectsResult & WithContents(ContentsT &&value)
ListObjectsResult & WithRequestId(RequestIdT &&value)
Aws::Http::HttpResponseCode GetHttpResponseCode() const
ListObjectsResult & WithIsTruncated(bool value)
const Aws::String & GetPrefix() const
const Aws::String & GetDelimiter() const
ListObjectsResult & WithCommonPrefixes(CommonPrefixesT &&value)
void SetRequestCharged(RequestCharged value)
ListObjectsResult & WithNextMarker(NextMarkerT &&value)
const Aws::String & GetRequestId() const
ListObjectsResult & AddCommonPrefixes(CommonPrefixesT &&value)
void SetNextMarker(NextMarkerT &&value)
AWS_S3CRT_API ListObjectsResult & operator=(const Aws::AmazonWebServiceResult< Aws::Utils::Xml::XmlDocument > &result)
ListObjectsResult & WithRequestCharged(RequestCharged value)
ListObjectsResult & WithPrefix(PrefixT &&value)
const Aws::Vector< Object > & GetContents() const
ListObjectsResult & WithDelimiter(DelimiterT &&value)
ListObjectsResult & AddContents(ContentsT &&value)
AWS_S3CRT_API ListObjectsResult(const Aws::AmazonWebServiceResult< Aws::Utils::Xml::XmlDocument > &result)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Xml::XmlDocument XmlDocument