AWS SDK for C++  1.9.72
AWS SDK for C++
OnDemandOptions.h
Go to the documentation of this file.
1 
6 #pragma once
7 #include <aws/ec2/EC2_EXPORTS.h>
12 #include <utility>
13 
14 namespace Aws
15 {
16 namespace Utils
17 {
18 namespace Xml
19 {
20  class XmlNode;
21 } // namespace Xml
22 } // namespace Utils
23 namespace EC2
24 {
25 namespace Model
26 {
27 
35  {
36  public:
40 
41  void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
42  void OutputToStream(Aws::OStream& oStream, const char* location) const;
43 
44 
53  inline const FleetOnDemandAllocationStrategy& GetAllocationStrategy() const{ return m_allocationStrategy; }
54 
63  inline bool AllocationStrategyHasBeenSet() const { return m_allocationStrategyHasBeenSet; }
64 
73  inline void SetAllocationStrategy(const FleetOnDemandAllocationStrategy& value) { m_allocationStrategyHasBeenSet = true; m_allocationStrategy = value; }
74 
83  inline void SetAllocationStrategy(FleetOnDemandAllocationStrategy&& value) { m_allocationStrategyHasBeenSet = true; m_allocationStrategy = std::move(value); }
84 
93  inline OnDemandOptions& WithAllocationStrategy(const FleetOnDemandAllocationStrategy& value) { SetAllocationStrategy(value); return *this;}
94 
103  inline OnDemandOptions& WithAllocationStrategy(FleetOnDemandAllocationStrategy&& value) { SetAllocationStrategy(std::move(value)); return *this;}
104 
105 
110  inline const CapacityReservationOptions& GetCapacityReservationOptions() const{ return m_capacityReservationOptions; }
111 
116  inline bool CapacityReservationOptionsHasBeenSet() const { return m_capacityReservationOptionsHasBeenSet; }
117 
122  inline void SetCapacityReservationOptions(const CapacityReservationOptions& value) { m_capacityReservationOptionsHasBeenSet = true; m_capacityReservationOptions = value; }
123 
128  inline void SetCapacityReservationOptions(CapacityReservationOptions&& value) { m_capacityReservationOptionsHasBeenSet = true; m_capacityReservationOptions = std::move(value); }
129 
134  inline OnDemandOptions& WithCapacityReservationOptions(const CapacityReservationOptions& value) { SetCapacityReservationOptions(value); return *this;}
135 
140  inline OnDemandOptions& WithCapacityReservationOptions(CapacityReservationOptions&& value) { SetCapacityReservationOptions(std::move(value)); return *this;}
141 
142 
148  inline bool GetSingleInstanceType() const{ return m_singleInstanceType; }
149 
155  inline bool SingleInstanceTypeHasBeenSet() const { return m_singleInstanceTypeHasBeenSet; }
156 
162  inline void SetSingleInstanceType(bool value) { m_singleInstanceTypeHasBeenSet = true; m_singleInstanceType = value; }
163 
169  inline OnDemandOptions& WithSingleInstanceType(bool value) { SetSingleInstanceType(value); return *this;}
170 
171 
176  inline bool GetSingleAvailabilityZone() const{ return m_singleAvailabilityZone; }
177 
182  inline bool SingleAvailabilityZoneHasBeenSet() const { return m_singleAvailabilityZoneHasBeenSet; }
183 
188  inline void SetSingleAvailabilityZone(bool value) { m_singleAvailabilityZoneHasBeenSet = true; m_singleAvailabilityZone = value; }
189 
194  inline OnDemandOptions& WithSingleAvailabilityZone(bool value) { SetSingleAvailabilityZone(value); return *this;}
195 
196 
201  inline int GetMinTargetCapacity() const{ return m_minTargetCapacity; }
202 
207  inline bool MinTargetCapacityHasBeenSet() const { return m_minTargetCapacityHasBeenSet; }
208 
213  inline void SetMinTargetCapacity(int value) { m_minTargetCapacityHasBeenSet = true; m_minTargetCapacity = value; }
214 
219  inline OnDemandOptions& WithMinTargetCapacity(int value) { SetMinTargetCapacity(value); return *this;}
220 
221 
226  inline const Aws::String& GetMaxTotalPrice() const{ return m_maxTotalPrice; }
227 
232  inline bool MaxTotalPriceHasBeenSet() const { return m_maxTotalPriceHasBeenSet; }
233 
238  inline void SetMaxTotalPrice(const Aws::String& value) { m_maxTotalPriceHasBeenSet = true; m_maxTotalPrice = value; }
239 
244  inline void SetMaxTotalPrice(Aws::String&& value) { m_maxTotalPriceHasBeenSet = true; m_maxTotalPrice = std::move(value); }
245 
250  inline void SetMaxTotalPrice(const char* value) { m_maxTotalPriceHasBeenSet = true; m_maxTotalPrice.assign(value); }
251 
256  inline OnDemandOptions& WithMaxTotalPrice(const Aws::String& value) { SetMaxTotalPrice(value); return *this;}
257 
262  inline OnDemandOptions& WithMaxTotalPrice(Aws::String&& value) { SetMaxTotalPrice(std::move(value)); return *this;}
263 
268  inline OnDemandOptions& WithMaxTotalPrice(const char* value) { SetMaxTotalPrice(value); return *this;}
269 
270  private:
271 
272  FleetOnDemandAllocationStrategy m_allocationStrategy;
273  bool m_allocationStrategyHasBeenSet;
274 
275  CapacityReservationOptions m_capacityReservationOptions;
276  bool m_capacityReservationOptionsHasBeenSet;
277 
278  bool m_singleInstanceType;
279  bool m_singleInstanceTypeHasBeenSet;
280 
281  bool m_singleAvailabilityZone;
282  bool m_singleAvailabilityZoneHasBeenSet;
283 
284  int m_minTargetCapacity;
285  bool m_minTargetCapacityHasBeenSet;
286 
287  Aws::String m_maxTotalPrice;
288  bool m_maxTotalPriceHasBeenSet;
289  };
290 
291 } // namespace Model
292 } // namespace EC2
293 } // namespace Aws
Aws::EC2::Model::FleetOnDemandAllocationStrategy
FleetOnDemandAllocationStrategy
Definition: FleetOnDemandAllocationStrategy.h:17
Aws::EC2::Model::OnDemandOptions::WithAllocationStrategy
OnDemandOptions & WithAllocationStrategy(FleetOnDemandAllocationStrategy &&value)
Definition: OnDemandOptions.h:103
Aws::EC2::Model::OnDemandOptions::GetAllocationStrategy
const FleetOnDemandAllocationStrategy & GetAllocationStrategy() const
Definition: OnDemandOptions.h:53
Aws::EC2::Model::OnDemandOptions::SingleAvailabilityZoneHasBeenSet
bool SingleAvailabilityZoneHasBeenSet() const
Definition: OnDemandOptions.h:182
Aws::EC2::Model::OnDemandOptions::CapacityReservationOptionsHasBeenSet
bool CapacityReservationOptionsHasBeenSet() const
Definition: OnDemandOptions.h:116
AWS_EC2_API
#define AWS_EC2_API
Definition: EC2_EXPORTS.h:28
Aws::EC2::Model::OnDemandOptions::GetMinTargetCapacity
int GetMinTargetCapacity() const
Definition: OnDemandOptions.h:201
Aws::EC2::Model::OnDemandOptions::WithMaxTotalPrice
OnDemandOptions & WithMaxTotalPrice(const char *value)
Definition: OnDemandOptions.h:268
Aws::EC2::Model::OnDemandOptions::SetMaxTotalPrice
void SetMaxTotalPrice(const char *value)
Definition: OnDemandOptions.h:250
AWSStreamFwd.h
Aws::EC2::Model::OnDemandOptions::WithMaxTotalPrice
OnDemandOptions & WithMaxTotalPrice(Aws::String &&value)
Definition: OnDemandOptions.h:262
Aws::EC2::Model::OnDemandOptions::WithAllocationStrategy
OnDemandOptions & WithAllocationStrategy(const FleetOnDemandAllocationStrategy &value)
Definition: OnDemandOptions.h:93
Aws::OStream
std::basic_ostream< char, std::char_traits< char > > OStream
Definition: AWSStreamFwd.h:21
Aws::EC2::Model::OnDemandOptions::OnDemandOptions
OnDemandOptions(const Aws::Utils::Xml::XmlNode &xmlNode)
Aws::EC2::Model::OnDemandOptions::WithCapacityReservationOptions
OnDemandOptions & WithCapacityReservationOptions(CapacityReservationOptions &&value)
Definition: OnDemandOptions.h:140
Aws::EC2::Model::OnDemandOptions::GetSingleAvailabilityZone
bool GetSingleAvailabilityZone() const
Definition: OnDemandOptions.h:176
Aws::EC2::Model::OnDemandOptions::SingleInstanceTypeHasBeenSet
bool SingleInstanceTypeHasBeenSet() const
Definition: OnDemandOptions.h:155
Aws::Utils::Xml::XmlNode
Definition: XmlSerializer.h:53
Aws::EC2::Model::OnDemandOptions::SetAllocationStrategy
void SetAllocationStrategy(const FleetOnDemandAllocationStrategy &value)
Definition: OnDemandOptions.h:73
Aws::EC2::Model::OnDemandOptions::SetMaxTotalPrice
void SetMaxTotalPrice(Aws::String &&value)
Definition: OnDemandOptions.h:244
Aws::EC2::Model::OnDemandOptions::AllocationStrategyHasBeenSet
bool AllocationStrategyHasBeenSet() const
Definition: OnDemandOptions.h:63
Aws::EC2::Model::OnDemandOptions
Definition: OnDemandOptions.h:35
Aws::EC2::Model::OnDemandOptions::WithMaxTotalPrice
OnDemandOptions & WithMaxTotalPrice(const Aws::String &value)
Definition: OnDemandOptions.h:256
FleetOnDemandAllocationStrategy.h
AWSString.h
Aws::EC2::Model::OnDemandOptions::WithCapacityReservationOptions
OnDemandOptions & WithCapacityReservationOptions(const CapacityReservationOptions &value)
Definition: OnDemandOptions.h:134
Aws::EC2::Model::CapacityReservationOptions
Definition: CapacityReservationOptions.h:41
Aws::EC2::Model::OnDemandOptions::SetSingleInstanceType
void SetSingleInstanceType(bool value)
Definition: OnDemandOptions.h:162
Aws::EC2::Model::OnDemandOptions::WithSingleAvailabilityZone
OnDemandOptions & WithSingleAvailabilityZone(bool value)
Definition: OnDemandOptions.h:194
Aws::EC2::Model::OnDemandOptions::GetCapacityReservationOptions
const CapacityReservationOptions & GetCapacityReservationOptions() const
Definition: OnDemandOptions.h:110
Aws::EC2::Model::OnDemandOptions::WithSingleInstanceType
OnDemandOptions & WithSingleInstanceType(bool value)
Definition: OnDemandOptions.h:169
Aws::EC2::Model::OnDemandOptions::SetCapacityReservationOptions
void SetCapacityReservationOptions(const CapacityReservationOptions &value)
Definition: OnDemandOptions.h:122
Aws::EC2::Model::OnDemandOptions::OnDemandOptions
OnDemandOptions()
Aws::EC2::Model::OnDemandOptions::SetCapacityReservationOptions
void SetCapacityReservationOptions(CapacityReservationOptions &&value)
Definition: OnDemandOptions.h:128
Aws::EC2::Model::OnDemandOptions::SetAllocationStrategy
void SetAllocationStrategy(FleetOnDemandAllocationStrategy &&value)
Definition: OnDemandOptions.h:83
CapacityReservationOptions.h
Aws::EC2::Model::OnDemandOptions::MaxTotalPriceHasBeenSet
bool MaxTotalPriceHasBeenSet() const
Definition: OnDemandOptions.h:232
Aws::EC2::Model::OnDemandOptions::SetSingleAvailabilityZone
void SetSingleAvailabilityZone(bool value)
Definition: OnDemandOptions.h:188
Aws::EC2::Model::OnDemandOptions::GetSingleInstanceType
bool GetSingleInstanceType() const
Definition: OnDemandOptions.h:148
Aws::EC2::Model::OnDemandOptions::WithMinTargetCapacity
OnDemandOptions & WithMinTargetCapacity(int value)
Definition: OnDemandOptions.h:219
Aws::EC2::Model::OnDemandOptions::OutputToStream
void OutputToStream(Aws::OStream &oStream, const char *location) const
Aws
Definition: AccessManagementClient.h:15
Aws::String
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
Aws::EC2::Model::OnDemandOptions::operator=
OnDemandOptions & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
Aws::EC2::Model::OnDemandOptions::MinTargetCapacityHasBeenSet
bool MinTargetCapacityHasBeenSet() const
Definition: OnDemandOptions.h:207
index
int index
Definition: cJSON.h:181
EC2_EXPORTS.h
Aws::EC2::Model::OnDemandOptions::GetMaxTotalPrice
const Aws::String & GetMaxTotalPrice() const
Definition: OnDemandOptions.h:226
Aws::EC2::Model::OnDemandOptions::SetMinTargetCapacity
void SetMinTargetCapacity(int value)
Definition: OnDemandOptions.h:213
Aws::EC2::Model::OnDemandOptions::SetMaxTotalPrice
void SetMaxTotalPrice(const Aws::String &value)
Definition: OnDemandOptions.h:238
Aws::EC2::Model::OnDemandOptions::OutputToStream
void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const