AWS SDK for C++

AWS SDK for C++ Version 1.11.607

Loading...
Searching...
No Matches
ReservedInstanceOffering.h
1
6#pragma once
7#include <aws/opensearch/OpenSearchService_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/opensearch/model/OpenSearchPartitionInstanceType.h>
10#include <aws/opensearch/model/ReservedInstancePaymentOption.h>
11#include <aws/core/utils/memory/stl/AWSVector.h>
12#include <aws/opensearch/model/RecurringCharge.h>
13#include <utility>
14
15namespace Aws
16{
17namespace Utils
18{
19namespace Json
20{
21 class JsonValue;
22 class JsonView;
23} // namespace Json
24} // namespace Utils
25namespace OpenSearchService
26{
27namespace Model
28{
29
37 {
38 public:
39 AWS_OPENSEARCHSERVICE_API ReservedInstanceOffering() = default;
40 AWS_OPENSEARCHSERVICE_API ReservedInstanceOffering(Aws::Utils::Json::JsonView jsonValue);
41 AWS_OPENSEARCHSERVICE_API ReservedInstanceOffering& operator=(Aws::Utils::Json::JsonView jsonValue);
42 AWS_OPENSEARCHSERVICE_API Aws::Utils::Json::JsonValue Jsonize() const;
43
44
46
49 inline const Aws::String& GetReservedInstanceOfferingId() const { return m_reservedInstanceOfferingId; }
50 inline bool ReservedInstanceOfferingIdHasBeenSet() const { return m_reservedInstanceOfferingIdHasBeenSet; }
51 template<typename ReservedInstanceOfferingIdT = Aws::String>
52 void SetReservedInstanceOfferingId(ReservedInstanceOfferingIdT&& value) { m_reservedInstanceOfferingIdHasBeenSet = true; m_reservedInstanceOfferingId = std::forward<ReservedInstanceOfferingIdT>(value); }
53 template<typename ReservedInstanceOfferingIdT = Aws::String>
54 ReservedInstanceOffering& WithReservedInstanceOfferingId(ReservedInstanceOfferingIdT&& value) { SetReservedInstanceOfferingId(std::forward<ReservedInstanceOfferingIdT>(value)); return *this;}
56
58
61 inline OpenSearchPartitionInstanceType GetInstanceType() const { return m_instanceType; }
62 inline bool InstanceTypeHasBeenSet() const { return m_instanceTypeHasBeenSet; }
63 inline void SetInstanceType(OpenSearchPartitionInstanceType value) { m_instanceTypeHasBeenSet = true; m_instanceType = value; }
66
68
72 inline int GetDuration() const { return m_duration; }
73 inline bool DurationHasBeenSet() const { return m_durationHasBeenSet; }
74 inline void SetDuration(int value) { m_durationHasBeenSet = true; m_duration = value; }
75 inline ReservedInstanceOffering& WithDuration(int value) { SetDuration(value); return *this;}
77
79
83 inline double GetFixedPrice() const { return m_fixedPrice; }
84 inline bool FixedPriceHasBeenSet() const { return m_fixedPriceHasBeenSet; }
85 inline void SetFixedPrice(double value) { m_fixedPriceHasBeenSet = true; m_fixedPrice = value; }
86 inline ReservedInstanceOffering& WithFixedPrice(double value) { SetFixedPrice(value); return *this;}
88
90
94 inline double GetUsagePrice() const { return m_usagePrice; }
95 inline bool UsagePriceHasBeenSet() const { return m_usagePriceHasBeenSet; }
96 inline void SetUsagePrice(double value) { m_usagePriceHasBeenSet = true; m_usagePrice = value; }
97 inline ReservedInstanceOffering& WithUsagePrice(double value) { SetUsagePrice(value); return *this;}
99
101
104 inline const Aws::String& GetCurrencyCode() const { return m_currencyCode; }
105 inline bool CurrencyCodeHasBeenSet() const { return m_currencyCodeHasBeenSet; }
106 template<typename CurrencyCodeT = Aws::String>
107 void SetCurrencyCode(CurrencyCodeT&& value) { m_currencyCodeHasBeenSet = true; m_currencyCode = std::forward<CurrencyCodeT>(value); }
108 template<typename CurrencyCodeT = Aws::String>
109 ReservedInstanceOffering& WithCurrencyCode(CurrencyCodeT&& value) { SetCurrencyCode(std::forward<CurrencyCodeT>(value)); return *this;}
111
113
116 inline ReservedInstancePaymentOption GetPaymentOption() const { return m_paymentOption; }
117 inline bool PaymentOptionHasBeenSet() const { return m_paymentOptionHasBeenSet; }
118 inline void SetPaymentOption(ReservedInstancePaymentOption value) { m_paymentOptionHasBeenSet = true; m_paymentOption = value; }
121
123
127 inline const Aws::Vector<RecurringCharge>& GetRecurringCharges() const { return m_recurringCharges; }
128 inline bool RecurringChargesHasBeenSet() const { return m_recurringChargesHasBeenSet; }
129 template<typename RecurringChargesT = Aws::Vector<RecurringCharge>>
130 void SetRecurringCharges(RecurringChargesT&& value) { m_recurringChargesHasBeenSet = true; m_recurringCharges = std::forward<RecurringChargesT>(value); }
131 template<typename RecurringChargesT = Aws::Vector<RecurringCharge>>
132 ReservedInstanceOffering& WithRecurringCharges(RecurringChargesT&& value) { SetRecurringCharges(std::forward<RecurringChargesT>(value)); return *this;}
133 template<typename RecurringChargesT = RecurringCharge>
134 ReservedInstanceOffering& AddRecurringCharges(RecurringChargesT&& value) { m_recurringChargesHasBeenSet = true; m_recurringCharges.emplace_back(std::forward<RecurringChargesT>(value)); return *this; }
136 private:
137
138 Aws::String m_reservedInstanceOfferingId;
139 bool m_reservedInstanceOfferingIdHasBeenSet = false;
140
142 bool m_instanceTypeHasBeenSet = false;
143
144 int m_duration{0};
145 bool m_durationHasBeenSet = false;
146
147 double m_fixedPrice{0.0};
148 bool m_fixedPriceHasBeenSet = false;
149
150 double m_usagePrice{0.0};
151 bool m_usagePriceHasBeenSet = false;
152
153 Aws::String m_currencyCode;
154 bool m_currencyCodeHasBeenSet = false;
155
157 bool m_paymentOptionHasBeenSet = false;
158
159 Aws::Vector<RecurringCharge> m_recurringCharges;
160 bool m_recurringChargesHasBeenSet = false;
161 };
162
163} // namespace Model
164} // namespace OpenSearchService
165} // namespace Aws
AWS_OPENSEARCHSERVICE_API ReservedInstanceOffering()=default
AWS_OPENSEARCHSERVICE_API ReservedInstanceOffering(Aws::Utils::Json::JsonView jsonValue)
ReservedInstanceOffering & WithCurrencyCode(CurrencyCodeT &&value)
void SetPaymentOption(ReservedInstancePaymentOption value)
ReservedInstanceOffering & WithPaymentOption(ReservedInstancePaymentOption value)
AWS_OPENSEARCHSERVICE_API Aws::Utils::Json::JsonValue Jsonize() const
ReservedInstanceOffering & WithRecurringCharges(RecurringChargesT &&value)
void SetInstanceType(OpenSearchPartitionInstanceType value)
ReservedInstanceOffering & WithInstanceType(OpenSearchPartitionInstanceType value)
ReservedInstanceOffering & WithReservedInstanceOfferingId(ReservedInstanceOfferingIdT &&value)
const Aws::Vector< RecurringCharge > & GetRecurringCharges() const
ReservedInstanceOffering & AddRecurringCharges(RecurringChargesT &&value)
void SetReservedInstanceOfferingId(ReservedInstanceOfferingIdT &&value)
AWS_OPENSEARCHSERVICE_API ReservedInstanceOffering & operator=(Aws::Utils::Json::JsonView jsonValue)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue