AWS SDK for C++
AWS SDK for C++
Loading...
Searching...
No Matches
Object.h
Go to the documentation of this file.
1
6#pragma once
7#include <aws/s3/S3_EXPORTS.h>
12#include <aws/s3/model/Owner.h>
14#include <utility>
15
16namespace Aws
17{
18namespace Utils
19{
20namespace Xml
21{
22 class XmlNode;
23} // namespace Xml
24} // namespace Utils
25namespace S3
26{
27namespace Model
28{
29
36 class Object
37 {
38 public:
42
44
45
50 inline const Aws::String& GetKey() const{ return m_key; }
51
56 inline bool KeyHasBeenSet() const { return m_keyHasBeenSet; }
57
62 inline void SetKey(const Aws::String& value) { m_keyHasBeenSet = true; m_key = value; }
63
68 inline void SetKey(Aws::String&& value) { m_keyHasBeenSet = true; m_key = std::move(value); }
69
74 inline void SetKey(const char* value) { m_keyHasBeenSet = true; m_key.assign(value); }
75
80 inline Object& WithKey(const Aws::String& value) { SetKey(value); return *this;}
81
86 inline Object& WithKey(Aws::String&& value) { SetKey(std::move(value)); return *this;}
87
92 inline Object& WithKey(const char* value) { SetKey(value); return *this;}
93
94
98 inline const Aws::Utils::DateTime& GetLastModified() const{ return m_lastModified; }
99
103 inline bool LastModifiedHasBeenSet() const { return m_lastModifiedHasBeenSet; }
104
108 inline void SetLastModified(const Aws::Utils::DateTime& value) { m_lastModifiedHasBeenSet = true; m_lastModified = value; }
109
113 inline void SetLastModified(Aws::Utils::DateTime&& value) { m_lastModifiedHasBeenSet = true; m_lastModified = std::move(value); }
114
118 inline Object& WithLastModified(const Aws::Utils::DateTime& value) { SetLastModified(value); return *this;}
119
123 inline Object& WithLastModified(Aws::Utils::DateTime&& value) { SetLastModified(std::move(value)); return *this;}
124
125
143 inline const Aws::String& GetETag() const{ return m_eTag; }
144
162 inline bool ETagHasBeenSet() const { return m_eTagHasBeenSet; }
163
181 inline void SetETag(const Aws::String& value) { m_eTagHasBeenSet = true; m_eTag = value; }
182
200 inline void SetETag(Aws::String&& value) { m_eTagHasBeenSet = true; m_eTag = std::move(value); }
201
219 inline void SetETag(const char* value) { m_eTagHasBeenSet = true; m_eTag.assign(value); }
220
238 inline Object& WithETag(const Aws::String& value) { SetETag(value); return *this;}
239
257 inline Object& WithETag(Aws::String&& value) { SetETag(std::move(value)); return *this;}
258
276 inline Object& WithETag(const char* value) { SetETag(value); return *this;}
277
278
282 inline const Aws::Vector<ChecksumAlgorithm>& GetChecksumAlgorithm() const{ return m_checksumAlgorithm; }
283
287 inline bool ChecksumAlgorithmHasBeenSet() const { return m_checksumAlgorithmHasBeenSet; }
288
292 inline void SetChecksumAlgorithm(const Aws::Vector<ChecksumAlgorithm>& value) { m_checksumAlgorithmHasBeenSet = true; m_checksumAlgorithm = value; }
293
297 inline void SetChecksumAlgorithm(Aws::Vector<ChecksumAlgorithm>&& value) { m_checksumAlgorithmHasBeenSet = true; m_checksumAlgorithm = std::move(value); }
298
303
307 inline Object& WithChecksumAlgorithm(Aws::Vector<ChecksumAlgorithm>&& value) { SetChecksumAlgorithm(std::move(value)); return *this;}
308
312 inline Object& AddChecksumAlgorithm(const ChecksumAlgorithm& value) { m_checksumAlgorithmHasBeenSet = true; m_checksumAlgorithm.push_back(value); return *this; }
313
317 inline Object& AddChecksumAlgorithm(ChecksumAlgorithm&& value) { m_checksumAlgorithmHasBeenSet = true; m_checksumAlgorithm.push_back(std::move(value)); return *this; }
318
319
323 inline long long GetSize() const{ return m_size; }
324
328 inline bool SizeHasBeenSet() const { return m_sizeHasBeenSet; }
329
333 inline void SetSize(long long value) { m_sizeHasBeenSet = true; m_size = value; }
334
338 inline Object& WithSize(long long value) { SetSize(value); return *this;}
339
340
344 inline const ObjectStorageClass& GetStorageClass() const{ return m_storageClass; }
345
349 inline bool StorageClassHasBeenSet() const { return m_storageClassHasBeenSet; }
350
354 inline void SetStorageClass(const ObjectStorageClass& value) { m_storageClassHasBeenSet = true; m_storageClass = value; }
355
359 inline void SetStorageClass(ObjectStorageClass&& value) { m_storageClassHasBeenSet = true; m_storageClass = std::move(value); }
360
364 inline Object& WithStorageClass(const ObjectStorageClass& value) { SetStorageClass(value); return *this;}
365
369 inline Object& WithStorageClass(ObjectStorageClass&& value) { SetStorageClass(std::move(value)); return *this;}
370
371
375 inline const Owner& GetOwner() const{ return m_owner; }
376
380 inline bool OwnerHasBeenSet() const { return m_ownerHasBeenSet; }
381
385 inline void SetOwner(const Owner& value) { m_ownerHasBeenSet = true; m_owner = value; }
386
390 inline void SetOwner(Owner&& value) { m_ownerHasBeenSet = true; m_owner = std::move(value); }
391
395 inline Object& WithOwner(const Owner& value) { SetOwner(value); return *this;}
396
400 inline Object& WithOwner(Owner&& value) { SetOwner(std::move(value)); return *this;}
401
402 private:
403
404 Aws::String m_key;
405 bool m_keyHasBeenSet = false;
406
407 Aws::Utils::DateTime m_lastModified;
408 bool m_lastModifiedHasBeenSet = false;
409
410 Aws::String m_eTag;
411 bool m_eTagHasBeenSet = false;
412
413 Aws::Vector<ChecksumAlgorithm> m_checksumAlgorithm;
414 bool m_checksumAlgorithmHasBeenSet = false;
415
416 long long m_size;
417 bool m_sizeHasBeenSet = false;
418
419 ObjectStorageClass m_storageClass;
420 bool m_storageClassHasBeenSet = false;
421
422 Owner m_owner;
423 bool m_ownerHasBeenSet = false;
424 };
425
426} // namespace Model
427} // namespace S3
428} // namespace Aws
#define AWS_S3_API
Definition: S3_EXPORTS.h:28
Object & AddChecksumAlgorithm(const ChecksumAlgorithm &value)
Definition: Object.h:312
AWS_S3_API Object & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
Object & WithETag(const char *value)
Definition: Object.h:276
bool SizeHasBeenSet() const
Definition: Object.h:328
void SetETag(const Aws::String &value)
Definition: Object.h:181
void SetETag(Aws::String &&value)
Definition: Object.h:200
AWS_S3_API void AddToNode(Aws::Utils::Xml::XmlNode &parentNode) const
void SetLastModified(const Aws::Utils::DateTime &value)
Definition: Object.h:108
Object & WithStorageClass(ObjectStorageClass &&value)
Definition: Object.h:369
Object & WithETag(Aws::String &&value)
Definition: Object.h:257
const Aws::String & GetKey() const
Definition: Object.h:50
Object & WithKey(const Aws::String &value)
Definition: Object.h:80
bool KeyHasBeenSet() const
Definition: Object.h:56
bool LastModifiedHasBeenSet() const
Definition: Object.h:103
const Owner & GetOwner() const
Definition: Object.h:375
const ObjectStorageClass & GetStorageClass() const
Definition: Object.h:344
Object & AddChecksumAlgorithm(ChecksumAlgorithm &&value)
Definition: Object.h:317
void SetKey(const char *value)
Definition: Object.h:74
Object & WithSize(long long value)
Definition: Object.h:338
Object & WithOwner(const Owner &value)
Definition: Object.h:395
void SetSize(long long value)
Definition: Object.h:333
Object & WithKey(const char *value)
Definition: Object.h:92
bool ChecksumAlgorithmHasBeenSet() const
Definition: Object.h:287
Object & WithKey(Aws::String &&value)
Definition: Object.h:86
Object & WithChecksumAlgorithm(const Aws::Vector< ChecksumAlgorithm > &value)
Definition: Object.h:302
void SetLastModified(Aws::Utils::DateTime &&value)
Definition: Object.h:113
bool StorageClassHasBeenSet() const
Definition: Object.h:349
void SetStorageClass(ObjectStorageClass &&value)
Definition: Object.h:359
Object & WithLastModified(const Aws::Utils::DateTime &value)
Definition: Object.h:118
long long GetSize() const
Definition: Object.h:323
void SetChecksumAlgorithm(Aws::Vector< ChecksumAlgorithm > &&value)
Definition: Object.h:297
void SetStorageClass(const ObjectStorageClass &value)
Definition: Object.h:354
Object & WithStorageClass(const ObjectStorageClass &value)
Definition: Object.h:364
void SetKey(const Aws::String &value)
Definition: Object.h:62
const Aws::String & GetETag() const
Definition: Object.h:143
bool OwnerHasBeenSet() const
Definition: Object.h:380
Object & WithETag(const Aws::String &value)
Definition: Object.h:238
Object & WithOwner(Owner &&value)
Definition: Object.h:400
const Aws::Vector< ChecksumAlgorithm > & GetChecksumAlgorithm() const
Definition: Object.h:282
void SetChecksumAlgorithm(const Aws::Vector< ChecksumAlgorithm > &value)
Definition: Object.h:292
void SetOwner(const Owner &value)
Definition: Object.h:385
AWS_S3_API Object(const Aws::Utils::Xml::XmlNode &xmlNode)
void SetKey(Aws::String &&value)
Definition: Object.h:68
Object & WithLastModified(Aws::Utils::DateTime &&value)
Definition: Object.h:123
void SetOwner(Owner &&value)
Definition: Object.h:390
bool ETagHasBeenSet() const
Definition: Object.h:162
void SetETag(const char *value)
Definition: Object.h:219
Object & WithChecksumAlgorithm(Aws::Vector< ChecksumAlgorithm > &&value)
Definition: Object.h:307
const Aws::Utils::DateTime & GetLastModified() const
Definition: Object.h:98
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector