AWS SDK for C++

AWS SDK for C++ Version 1.11.440

Loading...
Searching...
No Matches
OnDemandOptions.h
1
6#pragma once
7#include <aws/ec2/EC2_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSStreamFwd.h>
9#include <aws/ec2/model/FleetOnDemandAllocationStrategy.h>
10#include <aws/ec2/model/CapacityReservationOptions.h>
11#include <aws/core/utils/memory/stl/AWSString.h>
12#include <utility>
13
14namespace Aws
15{
16namespace Utils
17{
18namespace Xml
19{
20 class XmlNode;
21} // namespace Xml
22} // namespace Utils
23namespace EC2
24{
25namespace Model
26{
27
35 {
36 public:
37 AWS_EC2_API OnDemandOptions();
38 AWS_EC2_API OnDemandOptions(const Aws::Utils::Xml::XmlNode& xmlNode);
40
41 AWS_EC2_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
42 AWS_EC2_API void OutputToStream(Aws::OStream& oStream, const char* location) const;
43
44
46
54 inline const FleetOnDemandAllocationStrategy& GetAllocationStrategy() const{ return m_allocationStrategy; }
55 inline bool AllocationStrategyHasBeenSet() const { return m_allocationStrategyHasBeenSet; }
56 inline void SetAllocationStrategy(const FleetOnDemandAllocationStrategy& value) { m_allocationStrategyHasBeenSet = true; m_allocationStrategy = value; }
57 inline void SetAllocationStrategy(FleetOnDemandAllocationStrategy&& value) { m_allocationStrategyHasBeenSet = true; m_allocationStrategy = std::move(value); }
61
63
67 inline const CapacityReservationOptions& GetCapacityReservationOptions() const{ return m_capacityReservationOptions; }
68 inline bool CapacityReservationOptionsHasBeenSet() const { return m_capacityReservationOptionsHasBeenSet; }
69 inline void SetCapacityReservationOptions(const CapacityReservationOptions& value) { m_capacityReservationOptionsHasBeenSet = true; m_capacityReservationOptions = value; }
70 inline void SetCapacityReservationOptions(CapacityReservationOptions&& value) { m_capacityReservationOptionsHasBeenSet = true; m_capacityReservationOptions = std::move(value); }
74
76
81 inline bool GetSingleInstanceType() const{ return m_singleInstanceType; }
82 inline bool SingleInstanceTypeHasBeenSet() const { return m_singleInstanceTypeHasBeenSet; }
83 inline void SetSingleInstanceType(bool value) { m_singleInstanceTypeHasBeenSet = true; m_singleInstanceType = value; }
84 inline OnDemandOptions& WithSingleInstanceType(bool value) { SetSingleInstanceType(value); return *this;}
86
88
93 inline bool GetSingleAvailabilityZone() const{ return m_singleAvailabilityZone; }
94 inline bool SingleAvailabilityZoneHasBeenSet() const { return m_singleAvailabilityZoneHasBeenSet; }
95 inline void SetSingleAvailabilityZone(bool value) { m_singleAvailabilityZoneHasBeenSet = true; m_singleAvailabilityZone = value; }
96 inline OnDemandOptions& WithSingleAvailabilityZone(bool value) { SetSingleAvailabilityZone(value); return *this;}
98
100
107 inline int GetMinTargetCapacity() const{ return m_minTargetCapacity; }
108 inline bool MinTargetCapacityHasBeenSet() const { return m_minTargetCapacityHasBeenSet; }
109 inline void SetMinTargetCapacity(int value) { m_minTargetCapacityHasBeenSet = true; m_minTargetCapacity = value; }
110 inline OnDemandOptions& WithMinTargetCapacity(int value) { SetMinTargetCapacity(value); return *this;}
112
114
125 inline const Aws::String& GetMaxTotalPrice() const{ return m_maxTotalPrice; }
126 inline bool MaxTotalPriceHasBeenSet() const { return m_maxTotalPriceHasBeenSet; }
127 inline void SetMaxTotalPrice(const Aws::String& value) { m_maxTotalPriceHasBeenSet = true; m_maxTotalPrice = value; }
128 inline void SetMaxTotalPrice(Aws::String&& value) { m_maxTotalPriceHasBeenSet = true; m_maxTotalPrice = std::move(value); }
129 inline void SetMaxTotalPrice(const char* value) { m_maxTotalPriceHasBeenSet = true; m_maxTotalPrice.assign(value); }
130 inline OnDemandOptions& WithMaxTotalPrice(const Aws::String& value) { SetMaxTotalPrice(value); return *this;}
131 inline OnDemandOptions& WithMaxTotalPrice(Aws::String&& value) { SetMaxTotalPrice(std::move(value)); return *this;}
132 inline OnDemandOptions& WithMaxTotalPrice(const char* value) { SetMaxTotalPrice(value); return *this;}
134 private:
135
136 FleetOnDemandAllocationStrategy m_allocationStrategy;
137 bool m_allocationStrategyHasBeenSet = false;
138
139 CapacityReservationOptions m_capacityReservationOptions;
140 bool m_capacityReservationOptionsHasBeenSet = false;
141
142 bool m_singleInstanceType;
143 bool m_singleInstanceTypeHasBeenSet = false;
144
145 bool m_singleAvailabilityZone;
146 bool m_singleAvailabilityZoneHasBeenSet = false;
147
148 int m_minTargetCapacity;
149 bool m_minTargetCapacityHasBeenSet = false;
150
151 Aws::String m_maxTotalPrice;
152 bool m_maxTotalPriceHasBeenSet = false;
153 };
154
155} // namespace Model
156} // namespace EC2
157} // namespace Aws
OnDemandOptions & WithAllocationStrategy(FleetOnDemandAllocationStrategy &&value)
const Aws::String & GetMaxTotalPrice() const
const CapacityReservationOptions & GetCapacityReservationOptions() const
void SetSingleAvailabilityZone(bool value)
void SetMaxTotalPrice(const char *value)
OnDemandOptions & WithMinTargetCapacity(int value)
OnDemandOptions & WithMaxTotalPrice(Aws::String &&value)
OnDemandOptions & WithSingleAvailabilityZone(bool value)
OnDemandOptions & WithSingleInstanceType(bool value)
AWS_EC2_API OnDemandOptions(const Aws::Utils::Xml::XmlNode &xmlNode)
OnDemandOptions & WithMaxTotalPrice(const char *value)
OnDemandOptions & WithMaxTotalPrice(const Aws::String &value)
OnDemandOptions & WithCapacityReservationOptions(CapacityReservationOptions &&value)
void SetAllocationStrategy(FleetOnDemandAllocationStrategy &&value)
void SetAllocationStrategy(const FleetOnDemandAllocationStrategy &value)
bool CapacityReservationOptionsHasBeenSet() const
const FleetOnDemandAllocationStrategy & GetAllocationStrategy() const
OnDemandOptions & WithAllocationStrategy(const FleetOnDemandAllocationStrategy &value)
AWS_EC2_API void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
AWS_EC2_API void OutputToStream(Aws::OStream &oStream, const char *location) const
OnDemandOptions & WithCapacityReservationOptions(const CapacityReservationOptions &value)
void SetMaxTotalPrice(const Aws::String &value)
void SetCapacityReservationOptions(const CapacityReservationOptions &value)
void SetCapacityReservationOptions(CapacityReservationOptions &&value)
void SetMaxTotalPrice(Aws::String &&value)
AWS_EC2_API OnDemandOptions & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::basic_ostream< char, std::char_traits< char > > OStream