AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
DescribeSnapshotsRequest.h
1
6#pragma once
7#include <aws/ec2/EC2_EXPORTS.h>
8#include <aws/ec2/EC2Request.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/ec2/model/Filter.h>
12#include <utility>
13
14namespace Aws
15{
16namespace EC2
17{
18namespace Model
19{
20
24 {
25 public:
26 AWS_EC2_API DescribeSnapshotsRequest() = default;
27
28 // Service request name is the Operation name which will send this request out,
29 // each operation should has unique request name, so that we can get operation's name from this request.
30 // Note: this is not true for response, multiple operations may have the same response name,
31 // so we can not get operation's name from response.
32 inline virtual const char* GetServiceRequestName() const override { return "DescribeSnapshots"; }
33
34 AWS_EC2_API Aws::String SerializePayload() const override;
35
36 protected:
37 AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI& uri ) const override;
38
39 public:
40
42
48 inline int GetMaxResults() const { return m_maxResults; }
49 inline bool MaxResultsHasBeenSet() const { return m_maxResultsHasBeenSet; }
50 inline void SetMaxResults(int value) { m_maxResultsHasBeenSet = true; m_maxResults = value; }
51 inline DescribeSnapshotsRequest& WithMaxResults(int value) { SetMaxResults(value); return *this;}
53
55
59 inline const Aws::String& GetNextToken() const { return m_nextToken; }
60 inline bool NextTokenHasBeenSet() const { return m_nextTokenHasBeenSet; }
61 template<typename NextTokenT = Aws::String>
62 void SetNextToken(NextTokenT&& value) { m_nextTokenHasBeenSet = true; m_nextToken = std::forward<NextTokenT>(value); }
63 template<typename NextTokenT = Aws::String>
64 DescribeSnapshotsRequest& WithNextToken(NextTokenT&& value) { SetNextToken(std::forward<NextTokenT>(value)); return *this;}
66
68
73 inline const Aws::Vector<Aws::String>& GetOwnerIds() const { return m_ownerIds; }
74 inline bool OwnerIdsHasBeenSet() const { return m_ownerIdsHasBeenSet; }
75 template<typename OwnerIdsT = Aws::Vector<Aws::String>>
76 void SetOwnerIds(OwnerIdsT&& value) { m_ownerIdsHasBeenSet = true; m_ownerIds = std::forward<OwnerIdsT>(value); }
77 template<typename OwnerIdsT = Aws::Vector<Aws::String>>
78 DescribeSnapshotsRequest& WithOwnerIds(OwnerIdsT&& value) { SetOwnerIds(std::forward<OwnerIdsT>(value)); return *this;}
79 template<typename OwnerIdsT = Aws::String>
80 DescribeSnapshotsRequest& AddOwnerIds(OwnerIdsT&& value) { m_ownerIdsHasBeenSet = true; m_ownerIds.emplace_back(std::forward<OwnerIdsT>(value)); return *this; }
82
84
88 inline const Aws::Vector<Aws::String>& GetRestorableByUserIds() const { return m_restorableByUserIds; }
89 inline bool RestorableByUserIdsHasBeenSet() const { return m_restorableByUserIdsHasBeenSet; }
90 template<typename RestorableByUserIdsT = Aws::Vector<Aws::String>>
91 void SetRestorableByUserIds(RestorableByUserIdsT&& value) { m_restorableByUserIdsHasBeenSet = true; m_restorableByUserIds = std::forward<RestorableByUserIdsT>(value); }
92 template<typename RestorableByUserIdsT = Aws::Vector<Aws::String>>
93 DescribeSnapshotsRequest& WithRestorableByUserIds(RestorableByUserIdsT&& value) { SetRestorableByUserIds(std::forward<RestorableByUserIdsT>(value)); return *this;}
94 template<typename RestorableByUserIdsT = Aws::String>
95 DescribeSnapshotsRequest& AddRestorableByUserIds(RestorableByUserIdsT&& value) { m_restorableByUserIdsHasBeenSet = true; m_restorableByUserIds.emplace_back(std::forward<RestorableByUserIdsT>(value)); return *this; }
97
99
103 inline const Aws::Vector<Aws::String>& GetSnapshotIds() const { return m_snapshotIds; }
104 inline bool SnapshotIdsHasBeenSet() const { return m_snapshotIdsHasBeenSet; }
105 template<typename SnapshotIdsT = Aws::Vector<Aws::String>>
106 void SetSnapshotIds(SnapshotIdsT&& value) { m_snapshotIdsHasBeenSet = true; m_snapshotIds = std::forward<SnapshotIdsT>(value); }
107 template<typename SnapshotIdsT = Aws::Vector<Aws::String>>
108 DescribeSnapshotsRequest& WithSnapshotIds(SnapshotIdsT&& value) { SetSnapshotIds(std::forward<SnapshotIdsT>(value)); return *this;}
109 template<typename SnapshotIdsT = Aws::String>
110 DescribeSnapshotsRequest& AddSnapshotIds(SnapshotIdsT&& value) { m_snapshotIdsHasBeenSet = true; m_snapshotIds.emplace_back(std::forward<SnapshotIdsT>(value)); return *this; }
112
114
120 inline bool GetDryRun() const { return m_dryRun; }
121 inline bool DryRunHasBeenSet() const { return m_dryRunHasBeenSet; }
122 inline void SetDryRun(bool value) { m_dryRunHasBeenSet = true; m_dryRun = value; }
123 inline DescribeSnapshotsRequest& WithDryRun(bool value) { SetDryRun(value); return *this;}
125
127
158 inline const Aws::Vector<Filter>& GetFilters() const { return m_filters; }
159 inline bool FiltersHasBeenSet() const { return m_filtersHasBeenSet; }
160 template<typename FiltersT = Aws::Vector<Filter>>
161 void SetFilters(FiltersT&& value) { m_filtersHasBeenSet = true; m_filters = std::forward<FiltersT>(value); }
162 template<typename FiltersT = Aws::Vector<Filter>>
163 DescribeSnapshotsRequest& WithFilters(FiltersT&& value) { SetFilters(std::forward<FiltersT>(value)); return *this;}
164 template<typename FiltersT = Filter>
165 DescribeSnapshotsRequest& AddFilters(FiltersT&& value) { m_filtersHasBeenSet = true; m_filters.emplace_back(std::forward<FiltersT>(value)); return *this; }
167 private:
168
169 int m_maxResults{0};
170 bool m_maxResultsHasBeenSet = false;
171
172 Aws::String m_nextToken;
173 bool m_nextTokenHasBeenSet = false;
174
175 Aws::Vector<Aws::String> m_ownerIds;
176 bool m_ownerIdsHasBeenSet = false;
177
178 Aws::Vector<Aws::String> m_restorableByUserIds;
179 bool m_restorableByUserIdsHasBeenSet = false;
180
181 Aws::Vector<Aws::String> m_snapshotIds;
182 bool m_snapshotIdsHasBeenSet = false;
183
184 bool m_dryRun{false};
185 bool m_dryRunHasBeenSet = false;
186
187 Aws::Vector<Filter> m_filters;
188 bool m_filtersHasBeenSet = false;
189 };
190
191} // namespace Model
192} // namespace EC2
193} // namespace Aws
DescribeSnapshotsRequest & WithFilters(FiltersT &&value)
DescribeSnapshotsRequest & WithMaxResults(int value)
DescribeSnapshotsRequest & WithNextToken(NextTokenT &&value)
DescribeSnapshotsRequest & WithRestorableByUserIds(RestorableByUserIdsT &&value)
DescribeSnapshotsRequest & WithSnapshotIds(SnapshotIdsT &&value)
DescribeSnapshotsRequest & AddRestorableByUserIds(RestorableByUserIdsT &&value)
AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI &uri) const override
virtual const char * GetServiceRequestName() const override
const Aws::Vector< Aws::String > & GetRestorableByUserIds() const
const Aws::Vector< Aws::String > & GetSnapshotIds() const
AWS_EC2_API DescribeSnapshotsRequest()=default
DescribeSnapshotsRequest & AddSnapshotIds(SnapshotIdsT &&value)
DescribeSnapshotsRequest & WithDryRun(bool value)
AWS_EC2_API Aws::String SerializePayload() const override
const Aws::Vector< Aws::String > & GetOwnerIds() const
DescribeSnapshotsRequest & AddOwnerIds(OwnerIdsT &&value)
DescribeSnapshotsRequest & AddFilters(FiltersT &&value)
void SetRestorableByUserIds(RestorableByUserIdsT &&value)
const Aws::Vector< Filter > & GetFilters() const
DescribeSnapshotsRequest & WithOwnerIds(OwnerIdsT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector