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/application-autoscaling/ApplicationAutoScaling_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/application-autoscaling/model/ServiceNamespace.h>
10#include <aws/application-autoscaling/model/ScalableDimension.h>
11#include <aws/application-autoscaling/model/PolicyType.h>
12#include <aws/application-autoscaling/model/StepScalingPolicyConfiguration.h>
13#include <aws/application-autoscaling/model/TargetTrackingScalingPolicyConfiguration.h>
14#include <aws/core/utils/memory/stl/AWSVector.h>
15#include <aws/core/utils/DateTime.h>
16#include <aws/application-autoscaling/model/Alarm.h>
17#include <utility>
18
19namespace Aws
20{
21namespace Utils
22{
23namespace Json
24{
25 class JsonValue;
26 class JsonView;
27} // namespace Json
28} // namespace Utils
29namespace ApplicationAutoScaling
30{
31namespace Model
32{
33
45 {
46 public:
47 AWS_APPLICATIONAUTOSCALING_API ScalingPolicy();
48 AWS_APPLICATIONAUTOSCALING_API ScalingPolicy(Aws::Utils::Json::JsonView jsonValue);
49 AWS_APPLICATIONAUTOSCALING_API ScalingPolicy& operator=(Aws::Utils::Json::JsonView jsonValue);
50 AWS_APPLICATIONAUTOSCALING_API Aws::Utils::Json::JsonValue Jsonize() const;
51
52
54
57 inline const Aws::String& GetPolicyARN() const{ return m_policyARN; }
58 inline bool PolicyARNHasBeenSet() const { return m_policyARNHasBeenSet; }
59 inline void SetPolicyARN(const Aws::String& value) { m_policyARNHasBeenSet = true; m_policyARN = value; }
60 inline void SetPolicyARN(Aws::String&& value) { m_policyARNHasBeenSet = true; m_policyARN = std::move(value); }
61 inline void SetPolicyARN(const char* value) { m_policyARNHasBeenSet = true; m_policyARN.assign(value); }
62 inline ScalingPolicy& WithPolicyARN(const Aws::String& value) { SetPolicyARN(value); return *this;}
63 inline ScalingPolicy& WithPolicyARN(Aws::String&& value) { SetPolicyARN(std::move(value)); return *this;}
64 inline ScalingPolicy& WithPolicyARN(const char* value) { SetPolicyARN(value); return *this;}
66
68
71 inline const Aws::String& GetPolicyName() const{ return m_policyName; }
72 inline bool PolicyNameHasBeenSet() const { return m_policyNameHasBeenSet; }
73 inline void SetPolicyName(const Aws::String& value) { m_policyNameHasBeenSet = true; m_policyName = value; }
74 inline void SetPolicyName(Aws::String&& value) { m_policyNameHasBeenSet = true; m_policyName = std::move(value); }
75 inline void SetPolicyName(const char* value) { m_policyNameHasBeenSet = true; m_policyName.assign(value); }
76 inline ScalingPolicy& WithPolicyName(const Aws::String& value) { SetPolicyName(value); return *this;}
77 inline ScalingPolicy& WithPolicyName(Aws::String&& value) { SetPolicyName(std::move(value)); return *this;}
78 inline ScalingPolicy& WithPolicyName(const char* value) { SetPolicyName(value); return *this;}
80
82
86 inline const ServiceNamespace& GetServiceNamespace() const{ return m_serviceNamespace; }
87 inline bool ServiceNamespaceHasBeenSet() const { return m_serviceNamespaceHasBeenSet; }
88 inline void SetServiceNamespace(const ServiceNamespace& value) { m_serviceNamespaceHasBeenSet = true; m_serviceNamespace = value; }
89 inline void SetServiceNamespace(ServiceNamespace&& value) { m_serviceNamespaceHasBeenSet = true; m_serviceNamespace = std::move(value); }
90 inline ScalingPolicy& WithServiceNamespace(const ServiceNamespace& value) { SetServiceNamespace(value); return *this;}
91 inline ScalingPolicy& WithServiceNamespace(ServiceNamespace&& value) { SetServiceNamespace(std::move(value)); return *this;}
93
95
156 inline const Aws::String& GetResourceId() const{ return m_resourceId; }
157 inline bool ResourceIdHasBeenSet() const { return m_resourceIdHasBeenSet; }
158 inline void SetResourceId(const Aws::String& value) { m_resourceIdHasBeenSet = true; m_resourceId = value; }
159 inline void SetResourceId(Aws::String&& value) { m_resourceIdHasBeenSet = true; m_resourceId = std::move(value); }
160 inline void SetResourceId(const char* value) { m_resourceIdHasBeenSet = true; m_resourceId.assign(value); }
161 inline ScalingPolicy& WithResourceId(const Aws::String& value) { SetResourceId(value); return *this;}
162 inline ScalingPolicy& WithResourceId(Aws::String&& value) { SetResourceId(std::move(value)); return *this;}
163 inline ScalingPolicy& WithResourceId(const char* value) { SetResourceId(value); return *this;}
165
167
217 inline const ScalableDimension& GetScalableDimension() const{ return m_scalableDimension; }
218 inline bool ScalableDimensionHasBeenSet() const { return m_scalableDimensionHasBeenSet; }
219 inline void SetScalableDimension(const ScalableDimension& value) { m_scalableDimensionHasBeenSet = true; m_scalableDimension = value; }
220 inline void SetScalableDimension(ScalableDimension&& value) { m_scalableDimensionHasBeenSet = true; m_scalableDimension = std::move(value); }
221 inline ScalingPolicy& WithScalableDimension(const ScalableDimension& value) { SetScalableDimension(value); return *this;}
222 inline ScalingPolicy& WithScalableDimension(ScalableDimension&& value) { SetScalableDimension(std::move(value)); return *this;}
224
226
232 inline const PolicyType& GetPolicyType() const{ return m_policyType; }
233 inline bool PolicyTypeHasBeenSet() const { return m_policyTypeHasBeenSet; }
234 inline void SetPolicyType(const PolicyType& value) { m_policyTypeHasBeenSet = true; m_policyType = value; }
235 inline void SetPolicyType(PolicyType&& value) { m_policyTypeHasBeenSet = true; m_policyType = std::move(value); }
236 inline ScalingPolicy& WithPolicyType(const PolicyType& value) { SetPolicyType(value); return *this;}
237 inline ScalingPolicy& WithPolicyType(PolicyType&& value) { SetPolicyType(std::move(value)); return *this;}
239
241
244 inline const StepScalingPolicyConfiguration& GetStepScalingPolicyConfiguration() const{ return m_stepScalingPolicyConfiguration; }
245 inline bool StepScalingPolicyConfigurationHasBeenSet() const { return m_stepScalingPolicyConfigurationHasBeenSet; }
246 inline void SetStepScalingPolicyConfiguration(const StepScalingPolicyConfiguration& value) { m_stepScalingPolicyConfigurationHasBeenSet = true; m_stepScalingPolicyConfiguration = value; }
247 inline void SetStepScalingPolicyConfiguration(StepScalingPolicyConfiguration&& value) { m_stepScalingPolicyConfigurationHasBeenSet = true; m_stepScalingPolicyConfiguration = std::move(value); }
251
253
256 inline const TargetTrackingScalingPolicyConfiguration& GetTargetTrackingScalingPolicyConfiguration() const{ return m_targetTrackingScalingPolicyConfiguration; }
257 inline bool TargetTrackingScalingPolicyConfigurationHasBeenSet() const { return m_targetTrackingScalingPolicyConfigurationHasBeenSet; }
258 inline void SetTargetTrackingScalingPolicyConfiguration(const TargetTrackingScalingPolicyConfiguration& value) { m_targetTrackingScalingPolicyConfigurationHasBeenSet = true; m_targetTrackingScalingPolicyConfiguration = value; }
259 inline void SetTargetTrackingScalingPolicyConfiguration(TargetTrackingScalingPolicyConfiguration&& value) { m_targetTrackingScalingPolicyConfigurationHasBeenSet = true; m_targetTrackingScalingPolicyConfiguration = std::move(value); }
263
265
268 inline const Aws::Vector<Alarm>& GetAlarms() const{ return m_alarms; }
269 inline bool AlarmsHasBeenSet() const { return m_alarmsHasBeenSet; }
270 inline void SetAlarms(const Aws::Vector<Alarm>& value) { m_alarmsHasBeenSet = true; m_alarms = value; }
271 inline void SetAlarms(Aws::Vector<Alarm>&& value) { m_alarmsHasBeenSet = true; m_alarms = std::move(value); }
272 inline ScalingPolicy& WithAlarms(const Aws::Vector<Alarm>& value) { SetAlarms(value); return *this;}
273 inline ScalingPolicy& WithAlarms(Aws::Vector<Alarm>&& value) { SetAlarms(std::move(value)); return *this;}
274 inline ScalingPolicy& AddAlarms(const Alarm& value) { m_alarmsHasBeenSet = true; m_alarms.push_back(value); return *this; }
275 inline ScalingPolicy& AddAlarms(Alarm&& value) { m_alarmsHasBeenSet = true; m_alarms.push_back(std::move(value)); return *this; }
277
279
282 inline const Aws::Utils::DateTime& GetCreationTime() const{ return m_creationTime; }
283 inline bool CreationTimeHasBeenSet() const { return m_creationTimeHasBeenSet; }
284 inline void SetCreationTime(const Aws::Utils::DateTime& value) { m_creationTimeHasBeenSet = true; m_creationTime = value; }
285 inline void SetCreationTime(Aws::Utils::DateTime&& value) { m_creationTimeHasBeenSet = true; m_creationTime = std::move(value); }
286 inline ScalingPolicy& WithCreationTime(const Aws::Utils::DateTime& value) { SetCreationTime(value); return *this;}
287 inline ScalingPolicy& WithCreationTime(Aws::Utils::DateTime&& value) { SetCreationTime(std::move(value)); return *this;}
289 private:
290
291 Aws::String m_policyARN;
292 bool m_policyARNHasBeenSet = false;
293
294 Aws::String m_policyName;
295 bool m_policyNameHasBeenSet = false;
296
297 ServiceNamespace m_serviceNamespace;
298 bool m_serviceNamespaceHasBeenSet = false;
299
300 Aws::String m_resourceId;
301 bool m_resourceIdHasBeenSet = false;
302
303 ScalableDimension m_scalableDimension;
304 bool m_scalableDimensionHasBeenSet = false;
305
306 PolicyType m_policyType;
307 bool m_policyTypeHasBeenSet = false;
308
309 StepScalingPolicyConfiguration m_stepScalingPolicyConfiguration;
310 bool m_stepScalingPolicyConfigurationHasBeenSet = false;
311
312 TargetTrackingScalingPolicyConfiguration m_targetTrackingScalingPolicyConfiguration;
313 bool m_targetTrackingScalingPolicyConfigurationHasBeenSet = false;
314
315 Aws::Vector<Alarm> m_alarms;
316 bool m_alarmsHasBeenSet = false;
317
318 Aws::Utils::DateTime m_creationTime;
319 bool m_creationTimeHasBeenSet = false;
320 };
321
322} // namespace Model
323} // namespace ApplicationAutoScaling
324} // namespace Aws
ScalingPolicy & WithPolicyType(const PolicyType &value)
ScalingPolicy & WithServiceNamespace(const ServiceNamespace &value)
void SetServiceNamespace(ServiceNamespace &&value)
ScalingPolicy & WithResourceId(const char *value)
void SetPolicyARN(const Aws::String &value)
ScalingPolicy & WithPolicyARN(Aws::String &&value)
void SetPolicyName(const Aws::String &value)
ScalingPolicy & WithPolicyARN(const Aws::String &value)
ScalingPolicy & WithPolicyName(Aws::String &&value)
void SetAlarms(Aws::Vector< Alarm > &&value)
ScalingPolicy & WithPolicyName(const char *value)
void SetCreationTime(Aws::Utils::DateTime &&value)
void SetAlarms(const Aws::Vector< Alarm > &value)
void SetServiceNamespace(const ServiceNamespace &value)
const ServiceNamespace & GetServiceNamespace() const
AWS_APPLICATIONAUTOSCALING_API ScalingPolicy & operator=(Aws::Utils::Json::JsonView jsonValue)
ScalingPolicy & WithPolicyName(const Aws::String &value)
ScalingPolicy & AddAlarms(const Alarm &value)
ScalingPolicy & WithCreationTime(Aws::Utils::DateTime &&value)
AWS_APPLICATIONAUTOSCALING_API ScalingPolicy(Aws::Utils::Json::JsonView jsonValue)
const StepScalingPolicyConfiguration & GetStepScalingPolicyConfiguration() const
void SetTargetTrackingScalingPolicyConfiguration(const TargetTrackingScalingPolicyConfiguration &value)
ScalingPolicy & WithResourceId(const Aws::String &value)
ScalingPolicy & WithCreationTime(const Aws::Utils::DateTime &value)
const Aws::Vector< Alarm > & GetAlarms() const
void SetCreationTime(const Aws::Utils::DateTime &value)
const TargetTrackingScalingPolicyConfiguration & GetTargetTrackingScalingPolicyConfiguration() const
void SetStepScalingPolicyConfiguration(const StepScalingPolicyConfiguration &value)
ScalingPolicy & WithAlarms(Aws::Vector< Alarm > &&value)
ScalingPolicy & WithServiceNamespace(ServiceNamespace &&value)
ScalingPolicy & WithResourceId(Aws::String &&value)
ScalingPolicy & WithAlarms(const Aws::Vector< Alarm > &value)
ScalingPolicy & WithTargetTrackingScalingPolicyConfiguration(TargetTrackingScalingPolicyConfiguration &&value)
const Aws::Utils::DateTime & GetCreationTime() const
AWS_APPLICATIONAUTOSCALING_API ScalingPolicy()
ScalingPolicy & WithScalableDimension(const ScalableDimension &value)
ScalingPolicy & WithScalableDimension(ScalableDimension &&value)
ScalingPolicy & WithStepScalingPolicyConfiguration(StepScalingPolicyConfiguration &&value)
void SetScalableDimension(const ScalableDimension &value)
AWS_APPLICATIONAUTOSCALING_API Aws::Utils::Json::JsonValue Jsonize() const
void SetStepScalingPolicyConfiguration(StepScalingPolicyConfiguration &&value)
ScalingPolicy & WithPolicyARN(const char *value)
void SetScalableDimension(ScalableDimension &&value)
const ScalableDimension & GetScalableDimension() const
void SetTargetTrackingScalingPolicyConfiguration(TargetTrackingScalingPolicyConfiguration &&value)
ScalingPolicy & WithStepScalingPolicyConfiguration(const StepScalingPolicyConfiguration &value)
ScalingPolicy & WithTargetTrackingScalingPolicyConfiguration(const TargetTrackingScalingPolicyConfiguration &value)
ScalingPolicy & WithPolicyType(PolicyType &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue