/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace ECS { namespace Model { /** *

The details of the Auto Scaling group for the capacity * provider.

See Also:

AWS * API Reference

*/ class AutoScalingGroupProvider { public: AWS_ECS_API AutoScalingGroupProvider(); AWS_ECS_API AutoScalingGroupProvider(Aws::Utils::Json::JsonView jsonValue); AWS_ECS_API AutoScalingGroupProvider& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_ECS_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

The Amazon Resource Name (ARN) that identifies the Auto Scaling group.

*/ inline const Aws::String& GetAutoScalingGroupArn() const{ return m_autoScalingGroupArn; } /** *

The Amazon Resource Name (ARN) that identifies the Auto Scaling group.

*/ inline bool AutoScalingGroupArnHasBeenSet() const { return m_autoScalingGroupArnHasBeenSet; } /** *

The Amazon Resource Name (ARN) that identifies the Auto Scaling group.

*/ inline void SetAutoScalingGroupArn(const Aws::String& value) { m_autoScalingGroupArnHasBeenSet = true; m_autoScalingGroupArn = value; } /** *

The Amazon Resource Name (ARN) that identifies the Auto Scaling group.

*/ inline void SetAutoScalingGroupArn(Aws::String&& value) { m_autoScalingGroupArnHasBeenSet = true; m_autoScalingGroupArn = std::move(value); } /** *

The Amazon Resource Name (ARN) that identifies the Auto Scaling group.

*/ inline void SetAutoScalingGroupArn(const char* value) { m_autoScalingGroupArnHasBeenSet = true; m_autoScalingGroupArn.assign(value); } /** *

The Amazon Resource Name (ARN) that identifies the Auto Scaling group.

*/ inline AutoScalingGroupProvider& WithAutoScalingGroupArn(const Aws::String& value) { SetAutoScalingGroupArn(value); return *this;} /** *

The Amazon Resource Name (ARN) that identifies the Auto Scaling group.

*/ inline AutoScalingGroupProvider& WithAutoScalingGroupArn(Aws::String&& value) { SetAutoScalingGroupArn(std::move(value)); return *this;} /** *

The Amazon Resource Name (ARN) that identifies the Auto Scaling group.

*/ inline AutoScalingGroupProvider& WithAutoScalingGroupArn(const char* value) { SetAutoScalingGroupArn(value); return *this;} /** *

The managed scaling settings for the Auto Scaling group capacity * provider.

*/ inline const ManagedScaling& GetManagedScaling() const{ return m_managedScaling; } /** *

The managed scaling settings for the Auto Scaling group capacity * provider.

*/ inline bool ManagedScalingHasBeenSet() const { return m_managedScalingHasBeenSet; } /** *

The managed scaling settings for the Auto Scaling group capacity * provider.

*/ inline void SetManagedScaling(const ManagedScaling& value) { m_managedScalingHasBeenSet = true; m_managedScaling = value; } /** *

The managed scaling settings for the Auto Scaling group capacity * provider.

*/ inline void SetManagedScaling(ManagedScaling&& value) { m_managedScalingHasBeenSet = true; m_managedScaling = std::move(value); } /** *

The managed scaling settings for the Auto Scaling group capacity * provider.

*/ inline AutoScalingGroupProvider& WithManagedScaling(const ManagedScaling& value) { SetManagedScaling(value); return *this;} /** *

The managed scaling settings for the Auto Scaling group capacity * provider.

*/ inline AutoScalingGroupProvider& WithManagedScaling(ManagedScaling&& value) { SetManagedScaling(std::move(value)); return *this;} /** *

The managed termination protection setting to use for the Auto Scaling group * capacity provider. This determines whether the Auto Scaling group has managed * termination protection. The default is off.

When using * managed termination protection, managed scaling must also be used otherwise * managed termination protection doesn't work.

When managed * termination protection is on, Amazon ECS prevents the Amazon EC2 instances in an * Auto Scaling group that contain tasks from being terminated during a scale-in * action. The Auto Scaling group and each instance in the Auto Scaling group must * have instance protection from scale-in actions on as well. For more information, * see Instance * Protection in the Auto Scaling User Guide.

When managed * termination protection is off, your Amazon EC2 instances aren't protected from * termination when the Auto Scaling group scales in.

*/ inline const ManagedTerminationProtection& GetManagedTerminationProtection() const{ return m_managedTerminationProtection; } /** *

The managed termination protection setting to use for the Auto Scaling group * capacity provider. This determines whether the Auto Scaling group has managed * termination protection. The default is off.

When using * managed termination protection, managed scaling must also be used otherwise * managed termination protection doesn't work.

When managed * termination protection is on, Amazon ECS prevents the Amazon EC2 instances in an * Auto Scaling group that contain tasks from being terminated during a scale-in * action. The Auto Scaling group and each instance in the Auto Scaling group must * have instance protection from scale-in actions on as well. For more information, * see Instance * Protection in the Auto Scaling User Guide.

When managed * termination protection is off, your Amazon EC2 instances aren't protected from * termination when the Auto Scaling group scales in.

*/ inline bool ManagedTerminationProtectionHasBeenSet() const { return m_managedTerminationProtectionHasBeenSet; } /** *

The managed termination protection setting to use for the Auto Scaling group * capacity provider. This determines whether the Auto Scaling group has managed * termination protection. The default is off.

When using * managed termination protection, managed scaling must also be used otherwise * managed termination protection doesn't work.

When managed * termination protection is on, Amazon ECS prevents the Amazon EC2 instances in an * Auto Scaling group that contain tasks from being terminated during a scale-in * action. The Auto Scaling group and each instance in the Auto Scaling group must * have instance protection from scale-in actions on as well. For more information, * see Instance * Protection in the Auto Scaling User Guide.

When managed * termination protection is off, your Amazon EC2 instances aren't protected from * termination when the Auto Scaling group scales in.

*/ inline void SetManagedTerminationProtection(const ManagedTerminationProtection& value) { m_managedTerminationProtectionHasBeenSet = true; m_managedTerminationProtection = value; } /** *

The managed termination protection setting to use for the Auto Scaling group * capacity provider. This determines whether the Auto Scaling group has managed * termination protection. The default is off.

When using * managed termination protection, managed scaling must also be used otherwise * managed termination protection doesn't work.

When managed * termination protection is on, Amazon ECS prevents the Amazon EC2 instances in an * Auto Scaling group that contain tasks from being terminated during a scale-in * action. The Auto Scaling group and each instance in the Auto Scaling group must * have instance protection from scale-in actions on as well. For more information, * see Instance * Protection in the Auto Scaling User Guide.

When managed * termination protection is off, your Amazon EC2 instances aren't protected from * termination when the Auto Scaling group scales in.

*/ inline void SetManagedTerminationProtection(ManagedTerminationProtection&& value) { m_managedTerminationProtectionHasBeenSet = true; m_managedTerminationProtection = std::move(value); } /** *

The managed termination protection setting to use for the Auto Scaling group * capacity provider. This determines whether the Auto Scaling group has managed * termination protection. The default is off.

When using * managed termination protection, managed scaling must also be used otherwise * managed termination protection doesn't work.

When managed * termination protection is on, Amazon ECS prevents the Amazon EC2 instances in an * Auto Scaling group that contain tasks from being terminated during a scale-in * action. The Auto Scaling group and each instance in the Auto Scaling group must * have instance protection from scale-in actions on as well. For more information, * see Instance * Protection in the Auto Scaling User Guide.

When managed * termination protection is off, your Amazon EC2 instances aren't protected from * termination when the Auto Scaling group scales in.

*/ inline AutoScalingGroupProvider& WithManagedTerminationProtection(const ManagedTerminationProtection& value) { SetManagedTerminationProtection(value); return *this;} /** *

The managed termination protection setting to use for the Auto Scaling group * capacity provider. This determines whether the Auto Scaling group has managed * termination protection. The default is off.

When using * managed termination protection, managed scaling must also be used otherwise * managed termination protection doesn't work.

When managed * termination protection is on, Amazon ECS prevents the Amazon EC2 instances in an * Auto Scaling group that contain tasks from being terminated during a scale-in * action. The Auto Scaling group and each instance in the Auto Scaling group must * have instance protection from scale-in actions on as well. For more information, * see Instance * Protection in the Auto Scaling User Guide.

When managed * termination protection is off, your Amazon EC2 instances aren't protected from * termination when the Auto Scaling group scales in.

*/ inline AutoScalingGroupProvider& WithManagedTerminationProtection(ManagedTerminationProtection&& value) { SetManagedTerminationProtection(std::move(value)); return *this;} private: Aws::String m_autoScalingGroupArn; bool m_autoScalingGroupArnHasBeenSet = false; ManagedScaling m_managedScaling; bool m_managedScalingHasBeenSet = false; ManagedTerminationProtection m_managedTerminationProtection; bool m_managedTerminationProtectionHasBeenSet = false; }; } // namespace Model } // namespace ECS } // namespace Aws