AWS SDK for C++

AWS SDK for C++ Version 1.11.440

Loading...
Searching...
No Matches
ScalingPolicy.h
1
6#pragma once
7#include <aws/gamelift/GameLift_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/gamelift/model/ScalingStatusType.h>
10#include <aws/gamelift/model/ScalingAdjustmentType.h>
11#include <aws/gamelift/model/ComparisonOperatorType.h>
12#include <aws/gamelift/model/MetricName.h>
13#include <aws/gamelift/model/PolicyType.h>
14#include <aws/gamelift/model/TargetConfiguration.h>
15#include <aws/gamelift/model/LocationUpdateStatus.h>
16#include <utility>
17
18namespace Aws
19{
20namespace Utils
21{
22namespace Json
23{
24 class JsonValue;
25 class JsonView;
26} // namespace Json
27} // namespace Utils
28namespace GameLift
29{
30namespace Model
31{
32
41 {
42 public:
43 AWS_GAMELIFT_API ScalingPolicy();
44 AWS_GAMELIFT_API ScalingPolicy(Aws::Utils::Json::JsonView jsonValue);
46 AWS_GAMELIFT_API Aws::Utils::Json::JsonValue Jsonize() const;
47
48
50
54 inline const Aws::String& GetFleetId() const{ return m_fleetId; }
55 inline bool FleetIdHasBeenSet() const { return m_fleetIdHasBeenSet; }
56 inline void SetFleetId(const Aws::String& value) { m_fleetIdHasBeenSet = true; m_fleetId = value; }
57 inline void SetFleetId(Aws::String&& value) { m_fleetIdHasBeenSet = true; m_fleetId = std::move(value); }
58 inline void SetFleetId(const char* value) { m_fleetIdHasBeenSet = true; m_fleetId.assign(value); }
59 inline ScalingPolicy& WithFleetId(const Aws::String& value) { SetFleetId(value); return *this;}
60 inline ScalingPolicy& WithFleetId(Aws::String&& value) { SetFleetId(std::move(value)); return *this;}
61 inline ScalingPolicy& WithFleetId(const char* value) { SetFleetId(value); return *this;}
63
65
72 inline const Aws::String& GetFleetArn() const{ return m_fleetArn; }
73 inline bool FleetArnHasBeenSet() const { return m_fleetArnHasBeenSet; }
74 inline void SetFleetArn(const Aws::String& value) { m_fleetArnHasBeenSet = true; m_fleetArn = value; }
75 inline void SetFleetArn(Aws::String&& value) { m_fleetArnHasBeenSet = true; m_fleetArn = std::move(value); }
76 inline void SetFleetArn(const char* value) { m_fleetArnHasBeenSet = true; m_fleetArn.assign(value); }
77 inline ScalingPolicy& WithFleetArn(const Aws::String& value) { SetFleetArn(value); return *this;}
78 inline ScalingPolicy& WithFleetArn(Aws::String&& value) { SetFleetArn(std::move(value)); return *this;}
79 inline ScalingPolicy& WithFleetArn(const char* value) { SetFleetArn(value); return *this;}
81
83
87 inline const Aws::String& GetName() const{ return m_name; }
88 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
89 inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; }
90 inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); }
91 inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); }
92 inline ScalingPolicy& WithName(const Aws::String& value) { SetName(value); return *this;}
93 inline ScalingPolicy& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;}
94 inline ScalingPolicy& WithName(const char* value) { SetName(value); return *this;}
96
98
112 inline const ScalingStatusType& GetStatus() const{ return m_status; }
113 inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; }
114 inline void SetStatus(const ScalingStatusType& value) { m_statusHasBeenSet = true; m_status = value; }
115 inline void SetStatus(ScalingStatusType&& value) { m_statusHasBeenSet = true; m_status = std::move(value); }
116 inline ScalingPolicy& WithStatus(const ScalingStatusType& value) { SetStatus(value); return *this;}
117 inline ScalingPolicy& WithStatus(ScalingStatusType&& value) { SetStatus(std::move(value)); return *this;}
119
121
124 inline int GetScalingAdjustment() const{ return m_scalingAdjustment; }
125 inline bool ScalingAdjustmentHasBeenSet() const { return m_scalingAdjustmentHasBeenSet; }
126 inline void SetScalingAdjustment(int value) { m_scalingAdjustmentHasBeenSet = true; m_scalingAdjustment = value; }
127 inline ScalingPolicy& WithScalingAdjustment(int value) { SetScalingAdjustment(value); return *this;}
129
131
141 inline const ScalingAdjustmentType& GetScalingAdjustmentType() const{ return m_scalingAdjustmentType; }
142 inline bool ScalingAdjustmentTypeHasBeenSet() const { return m_scalingAdjustmentTypeHasBeenSet; }
143 inline void SetScalingAdjustmentType(const ScalingAdjustmentType& value) { m_scalingAdjustmentTypeHasBeenSet = true; m_scalingAdjustmentType = value; }
144 inline void SetScalingAdjustmentType(ScalingAdjustmentType&& value) { m_scalingAdjustmentTypeHasBeenSet = true; m_scalingAdjustmentType = std::move(value); }
148
150
154 inline const ComparisonOperatorType& GetComparisonOperator() const{ return m_comparisonOperator; }
155 inline bool ComparisonOperatorHasBeenSet() const { return m_comparisonOperatorHasBeenSet; }
156 inline void SetComparisonOperator(const ComparisonOperatorType& value) { m_comparisonOperatorHasBeenSet = true; m_comparisonOperator = value; }
157 inline void SetComparisonOperator(ComparisonOperatorType&& value) { m_comparisonOperatorHasBeenSet = true; m_comparisonOperator = std::move(value); }
159 inline ScalingPolicy& WithComparisonOperator(ComparisonOperatorType&& value) { SetComparisonOperator(std::move(value)); return *this;}
161
163
166 inline double GetThreshold() const{ return m_threshold; }
167 inline bool ThresholdHasBeenSet() const { return m_thresholdHasBeenSet; }
168 inline void SetThreshold(double value) { m_thresholdHasBeenSet = true; m_threshold = value; }
169 inline ScalingPolicy& WithThreshold(double value) { SetThreshold(value); return *this;}
171
173
177 inline int GetEvaluationPeriods() const{ return m_evaluationPeriods; }
178 inline bool EvaluationPeriodsHasBeenSet() const { return m_evaluationPeriodsHasBeenSet; }
179 inline void SetEvaluationPeriods(int value) { m_evaluationPeriodsHasBeenSet = true; m_evaluationPeriods = value; }
180 inline ScalingPolicy& WithEvaluationPeriods(int value) { SetEvaluationPeriods(value); return *this;}
182
184
212 inline const MetricName& GetMetricName() const{ return m_metricName; }
213 inline bool MetricNameHasBeenSet() const { return m_metricNameHasBeenSet; }
214 inline void SetMetricName(const MetricName& value) { m_metricNameHasBeenSet = true; m_metricName = value; }
215 inline void SetMetricName(MetricName&& value) { m_metricNameHasBeenSet = true; m_metricName = std::move(value); }
216 inline ScalingPolicy& WithMetricName(const MetricName& value) { SetMetricName(value); return *this;}
217 inline ScalingPolicy& WithMetricName(MetricName&& value) { SetMetricName(std::move(value)); return *this;}
219
221
229 inline const PolicyType& GetPolicyType() const{ return m_policyType; }
230 inline bool PolicyTypeHasBeenSet() const { return m_policyTypeHasBeenSet; }
231 inline void SetPolicyType(const PolicyType& value) { m_policyTypeHasBeenSet = true; m_policyType = value; }
232 inline void SetPolicyType(PolicyType&& value) { m_policyTypeHasBeenSet = true; m_policyType = std::move(value); }
233 inline ScalingPolicy& WithPolicyType(const PolicyType& value) { SetPolicyType(value); return *this;}
234 inline ScalingPolicy& WithPolicyType(PolicyType&& value) { SetPolicyType(std::move(value)); return *this;}
236
238
241 inline const TargetConfiguration& GetTargetConfiguration() const{ return m_targetConfiguration; }
242 inline bool TargetConfigurationHasBeenSet() const { return m_targetConfigurationHasBeenSet; }
243 inline void SetTargetConfiguration(const TargetConfiguration& value) { m_targetConfigurationHasBeenSet = true; m_targetConfiguration = value; }
244 inline void SetTargetConfiguration(TargetConfiguration&& value) { m_targetConfigurationHasBeenSet = true; m_targetConfiguration = std::move(value); }
246 inline ScalingPolicy& WithTargetConfiguration(TargetConfiguration&& value) { SetTargetConfiguration(std::move(value)); return *this;}
248
250
255 inline const LocationUpdateStatus& GetUpdateStatus() const{ return m_updateStatus; }
256 inline bool UpdateStatusHasBeenSet() const { return m_updateStatusHasBeenSet; }
257 inline void SetUpdateStatus(const LocationUpdateStatus& value) { m_updateStatusHasBeenSet = true; m_updateStatus = value; }
258 inline void SetUpdateStatus(LocationUpdateStatus&& value) { m_updateStatusHasBeenSet = true; m_updateStatus = std::move(value); }
259 inline ScalingPolicy& WithUpdateStatus(const LocationUpdateStatus& value) { SetUpdateStatus(value); return *this;}
260 inline ScalingPolicy& WithUpdateStatus(LocationUpdateStatus&& value) { SetUpdateStatus(std::move(value)); return *this;}
262
264
267 inline const Aws::String& GetLocation() const{ return m_location; }
268 inline bool LocationHasBeenSet() const { return m_locationHasBeenSet; }
269 inline void SetLocation(const Aws::String& value) { m_locationHasBeenSet = true; m_location = value; }
270 inline void SetLocation(Aws::String&& value) { m_locationHasBeenSet = true; m_location = std::move(value); }
271 inline void SetLocation(const char* value) { m_locationHasBeenSet = true; m_location.assign(value); }
272 inline ScalingPolicy& WithLocation(const Aws::String& value) { SetLocation(value); return *this;}
273 inline ScalingPolicy& WithLocation(Aws::String&& value) { SetLocation(std::move(value)); return *this;}
274 inline ScalingPolicy& WithLocation(const char* value) { SetLocation(value); return *this;}
276 private:
277
278 Aws::String m_fleetId;
279 bool m_fleetIdHasBeenSet = false;
280
281 Aws::String m_fleetArn;
282 bool m_fleetArnHasBeenSet = false;
283
284 Aws::String m_name;
285 bool m_nameHasBeenSet = false;
286
287 ScalingStatusType m_status;
288 bool m_statusHasBeenSet = false;
289
290 int m_scalingAdjustment;
291 bool m_scalingAdjustmentHasBeenSet = false;
292
293 ScalingAdjustmentType m_scalingAdjustmentType;
294 bool m_scalingAdjustmentTypeHasBeenSet = false;
295
296 ComparisonOperatorType m_comparisonOperator;
297 bool m_comparisonOperatorHasBeenSet = false;
298
299 double m_threshold;
300 bool m_thresholdHasBeenSet = false;
301
302 int m_evaluationPeriods;
303 bool m_evaluationPeriodsHasBeenSet = false;
304
305 MetricName m_metricName;
306 bool m_metricNameHasBeenSet = false;
307
308 PolicyType m_policyType;
309 bool m_policyTypeHasBeenSet = false;
310
311 TargetConfiguration m_targetConfiguration;
312 bool m_targetConfigurationHasBeenSet = false;
313
314 LocationUpdateStatus m_updateStatus;
315 bool m_updateStatusHasBeenSet = false;
316
317 Aws::String m_location;
318 bool m_locationHasBeenSet = false;
319 };
320
321} // namespace Model
322} // namespace GameLift
323} // namespace Aws
ScalingPolicy & WithStatus(ScalingStatusType &&value)
ScalingPolicy & WithScalingAdjustmentType(ScalingAdjustmentType &&value)
void SetStatus(ScalingStatusType &&value)
const ScalingStatusType & GetStatus() const
void SetScalingAdjustmentType(ScalingAdjustmentType &&value)
void SetComparisonOperator(ComparisonOperatorType &&value)
void SetTargetConfiguration(const TargetConfiguration &value)
void SetUpdateStatus(const LocationUpdateStatus &value)
ScalingPolicy & WithLocation(const char *value)
ScalingPolicy & WithName(const Aws::String &value)
ScalingPolicy & WithLocation(Aws::String &&value)
void SetLocation(const Aws::String &value)
void SetFleetId(const Aws::String &value)
void SetComparisonOperator(const ComparisonOperatorType &value)
ScalingPolicy & WithFleetId(Aws::String &&value)
const ComparisonOperatorType & GetComparisonOperator() const
void SetStatus(const ScalingStatusType &value)
void SetFleetArn(Aws::String &&value)
ScalingPolicy & WithFleetArn(const char *value)
void SetMetricName(MetricName &&value)
ScalingPolicy & WithUpdateStatus(LocationUpdateStatus &&value)
ScalingPolicy & WithMetricName(const MetricName &value)
void SetFleetArn(const char *value)
ScalingPolicy & WithTargetConfiguration(TargetConfiguration &&value)
ScalingPolicy & WithMetricName(MetricName &&value)
ScalingPolicy & WithFleetId(const Aws::String &value)
ScalingPolicy & WithComparisonOperator(const ComparisonOperatorType &value)
const MetricName & GetMetricName() const
ScalingPolicy & WithFleetArn(Aws::String &&value)
const Aws::String & GetName() const
void SetFleetId(const char *value)
ScalingPolicy & WithTargetConfiguration(const TargetConfiguration &value)
void SetPolicyType(PolicyType &&value)
void SetName(Aws::String &&value)
AWS_GAMELIFT_API ScalingPolicy & operator=(Aws::Utils::Json::JsonView jsonValue)
const TargetConfiguration & GetTargetConfiguration() const
ScalingPolicy & WithScalingAdjustment(int value)
ScalingPolicy & WithComparisonOperator(ComparisonOperatorType &&value)
ScalingPolicy & WithStatus(const ScalingStatusType &value)
const ScalingAdjustmentType & GetScalingAdjustmentType() const
ScalingPolicy & WithThreshold(double value)
ScalingPolicy & WithPolicyType(PolicyType &&value)
const LocationUpdateStatus & GetUpdateStatus() const
ScalingPolicy & WithEvaluationPeriods(int value)
void SetUpdateStatus(LocationUpdateStatus &&value)
AWS_GAMELIFT_API ScalingPolicy(Aws::Utils::Json::JsonView jsonValue)
ScalingPolicy & WithName(const char *value)
void SetName(const char *value)
AWS_GAMELIFT_API Aws::Utils::Json::JsonValue Jsonize() const
void SetLocation(const char *value)
void SetName(const Aws::String &value)
ScalingPolicy & WithFleetId(const char *value)
void SetPolicyType(const PolicyType &value)
ScalingPolicy & WithScalingAdjustmentType(const ScalingAdjustmentType &value)
void SetFleetArn(const Aws::String &value)
const Aws::String & GetFleetArn() const
ScalingPolicy & WithUpdateStatus(const LocationUpdateStatus &value)
void SetScalingAdjustmentType(const ScalingAdjustmentType &value)
void SetFleetId(Aws::String &&value)
const Aws::String & GetFleetId() const
ScalingPolicy & WithPolicyType(const PolicyType &value)
ScalingPolicy & WithLocation(const Aws::String &value)
const Aws::String & GetLocation() const
void SetTargetConfiguration(TargetConfiguration &&value)
void SetMetricName(const MetricName &value)
const PolicyType & GetPolicyType() const
ScalingPolicy & WithName(Aws::String &&value)
void SetLocation(Aws::String &&value)
ScalingPolicy & WithFleetArn(const Aws::String &value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue