AWS SDK for C++

AWS SDK for C++ Version 1.11.716

Loading...
Searching...
No Matches
Reservation.h
1
6#pragma once
7#include <aws/core/utils/DateTime.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/redshift-serverless/RedshiftServerless_EXPORTS.h>
10#include <aws/redshift-serverless/model/ReservationOffering.h>
11
12#include <utility>
13
14namespace Aws {
15namespace Utils {
16namespace Json {
17class JsonValue;
18class JsonView;
19} // namespace Json
20} // namespace Utils
21namespace RedshiftServerless {
22namespace Model {
23
33 public:
34 AWS_REDSHIFTSERVERLESS_API Reservation() = default;
35 AWS_REDSHIFTSERVERLESS_API Reservation(Aws::Utils::Json::JsonView jsonValue);
36 AWS_REDSHIFTSERVERLESS_API Reservation& operator=(Aws::Utils::Json::JsonView jsonValue);
37 AWS_REDSHIFTSERVERLESS_API Aws::Utils::Json::JsonValue Jsonize() const;
38
40
43 inline int GetCapacity() const { return m_capacity; }
44 inline bool CapacityHasBeenSet() const { return m_capacityHasBeenSet; }
45 inline void SetCapacity(int value) {
46 m_capacityHasBeenSet = true;
47 m_capacity = value;
48 }
49 inline Reservation& WithCapacity(int value) {
50 SetCapacity(value);
51 return *this;
52 }
54
56
60 inline const Aws::Utils::DateTime& GetEndDate() const { return m_endDate; }
61 inline bool EndDateHasBeenSet() const { return m_endDateHasBeenSet; }
62 template <typename EndDateT = Aws::Utils::DateTime>
63 void SetEndDate(EndDateT&& value) {
64 m_endDateHasBeenSet = true;
65 m_endDate = std::forward<EndDateT>(value);
66 }
67 template <typename EndDateT = Aws::Utils::DateTime>
68 Reservation& WithEndDate(EndDateT&& value) {
69 SetEndDate(std::forward<EndDateT>(value));
70 return *this;
71 }
73
75
79 inline const ReservationOffering& GetOffering() const { return m_offering; }
80 inline bool OfferingHasBeenSet() const { return m_offeringHasBeenSet; }
81 template <typename OfferingT = ReservationOffering>
82 void SetOffering(OfferingT&& value) {
83 m_offeringHasBeenSet = true;
84 m_offering = std::forward<OfferingT>(value);
85 }
86 template <typename OfferingT = ReservationOffering>
87 Reservation& WithOffering(OfferingT&& value) {
88 SetOffering(std::forward<OfferingT>(value));
89 return *this;
90 }
92
94
98 inline const Aws::String& GetReservationArn() const { return m_reservationArn; }
99 inline bool ReservationArnHasBeenSet() const { return m_reservationArnHasBeenSet; }
100 template <typename ReservationArnT = Aws::String>
101 void SetReservationArn(ReservationArnT&& value) {
102 m_reservationArnHasBeenSet = true;
103 m_reservationArn = std::forward<ReservationArnT>(value);
104 }
105 template <typename ReservationArnT = Aws::String>
106 Reservation& WithReservationArn(ReservationArnT&& value) {
107 SetReservationArn(std::forward<ReservationArnT>(value));
108 return *this;
109 }
111
113
116 inline const Aws::String& GetReservationId() const { return m_reservationId; }
117 inline bool ReservationIdHasBeenSet() const { return m_reservationIdHasBeenSet; }
118 template <typename ReservationIdT = Aws::String>
119 void SetReservationId(ReservationIdT&& value) {
120 m_reservationIdHasBeenSet = true;
121 m_reservationId = std::forward<ReservationIdT>(value);
122 }
123 template <typename ReservationIdT = Aws::String>
124 Reservation& WithReservationId(ReservationIdT&& value) {
125 SetReservationId(std::forward<ReservationIdT>(value));
126 return *this;
127 }
129
131
135 inline const Aws::Utils::DateTime& GetStartDate() const { return m_startDate; }
136 inline bool StartDateHasBeenSet() const { return m_startDateHasBeenSet; }
137 template <typename StartDateT = Aws::Utils::DateTime>
138 void SetStartDate(StartDateT&& value) {
139 m_startDateHasBeenSet = true;
140 m_startDate = std::forward<StartDateT>(value);
141 }
142 template <typename StartDateT = Aws::Utils::DateTime>
143 Reservation& WithStartDate(StartDateT&& value) {
144 SetStartDate(std::forward<StartDateT>(value));
145 return *this;
146 }
148
150
156 inline const Aws::String& GetStatus() const { return m_status; }
157 inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; }
158 template <typename StatusT = Aws::String>
159 void SetStatus(StatusT&& value) {
160 m_statusHasBeenSet = true;
161 m_status = std::forward<StatusT>(value);
162 }
163 template <typename StatusT = Aws::String>
164 Reservation& WithStatus(StatusT&& value) {
165 SetStatus(std::forward<StatusT>(value));
166 return *this;
167 }
169 private:
170 int m_capacity{0};
171
172 Aws::Utils::DateTime m_endDate{};
173
174 ReservationOffering m_offering;
175
176 Aws::String m_reservationArn;
177
178 Aws::String m_reservationId;
179
180 Aws::Utils::DateTime m_startDate{};
181
182 Aws::String m_status;
183 bool m_capacityHasBeenSet = false;
184 bool m_endDateHasBeenSet = false;
185 bool m_offeringHasBeenSet = false;
186 bool m_reservationArnHasBeenSet = false;
187 bool m_reservationIdHasBeenSet = false;
188 bool m_startDateHasBeenSet = false;
189 bool m_statusHasBeenSet = false;
190};
191
192} // namespace Model
193} // namespace RedshiftServerless
194} // namespace Aws
Reservation & WithReservationArn(ReservationArnT &&value)
AWS_REDSHIFTSERVERLESS_API Reservation()=default
Reservation & WithStatus(StatusT &&value)
const ReservationOffering & GetOffering() const
Definition Reservation.h:79
void SetReservationId(ReservationIdT &&value)
Reservation & WithEndDate(EndDateT &&value)
Definition Reservation.h:68
AWS_REDSHIFTSERVERLESS_API Aws::Utils::Json::JsonValue Jsonize() const
const Aws::String & GetStatus() const
const Aws::Utils::DateTime & GetStartDate() const
const Aws::String & GetReservationArn() const
Definition Reservation.h:98
AWS_REDSHIFTSERVERLESS_API Reservation & operator=(Aws::Utils::Json::JsonView jsonValue)
Reservation & WithReservationId(ReservationIdT &&value)
const Aws::String & GetReservationId() const
Reservation & WithStartDate(StartDateT &&value)
const Aws::Utils::DateTime & GetEndDate() const
Definition Reservation.h:60
Reservation & WithOffering(OfferingT &&value)
Definition Reservation.h:87
void SetReservationArn(ReservationArnT &&value)
AWS_REDSHIFTSERVERLESS_API Reservation(Aws::Utils::Json::JsonView jsonValue)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue