/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include namespace Aws { namespace ECS { namespace Model { /** */ class UpdateContainerInstancesStateRequest : public ECSRequest { public: AWS_ECS_API UpdateContainerInstancesStateRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "UpdateContainerInstancesState"; } AWS_ECS_API Aws::String SerializePayload() const override; AWS_ECS_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; /** *

The short name or full Amazon Resource Name (ARN) of the cluster that hosts * the container instance to update. If you do not specify a cluster, the default * cluster is assumed.

*/ inline const Aws::String& GetCluster() const{ return m_cluster; } /** *

The short name or full Amazon Resource Name (ARN) of the cluster that hosts * the container instance to update. If you do not specify a cluster, the default * cluster is assumed.

*/ inline bool ClusterHasBeenSet() const { return m_clusterHasBeenSet; } /** *

The short name or full Amazon Resource Name (ARN) of the cluster that hosts * the container instance to update. If you do not specify a cluster, the default * cluster is assumed.

*/ inline void SetCluster(const Aws::String& value) { m_clusterHasBeenSet = true; m_cluster = value; } /** *

The short name or full Amazon Resource Name (ARN) of the cluster that hosts * the container instance to update. If you do not specify a cluster, the default * cluster is assumed.

*/ inline void SetCluster(Aws::String&& value) { m_clusterHasBeenSet = true; m_cluster = std::move(value); } /** *

The short name or full Amazon Resource Name (ARN) of the cluster that hosts * the container instance to update. If you do not specify a cluster, the default * cluster is assumed.

*/ inline void SetCluster(const char* value) { m_clusterHasBeenSet = true; m_cluster.assign(value); } /** *

The short name or full Amazon Resource Name (ARN) of the cluster that hosts * the container instance to update. If you do not specify a cluster, the default * cluster is assumed.

*/ inline UpdateContainerInstancesStateRequest& WithCluster(const Aws::String& value) { SetCluster(value); return *this;} /** *

The short name or full Amazon Resource Name (ARN) of the cluster that hosts * the container instance to update. If you do not specify a cluster, the default * cluster is assumed.

*/ inline UpdateContainerInstancesStateRequest& WithCluster(Aws::String&& value) { SetCluster(std::move(value)); return *this;} /** *

The short name or full Amazon Resource Name (ARN) of the cluster that hosts * the container instance to update. If you do not specify a cluster, the default * cluster is assumed.

*/ inline UpdateContainerInstancesStateRequest& WithCluster(const char* value) { SetCluster(value); return *this;} /** *

A list of up to 10 container instance IDs or full ARN entries.

*/ inline const Aws::Vector& GetContainerInstances() const{ return m_containerInstances; } /** *

A list of up to 10 container instance IDs or full ARN entries.

*/ inline bool ContainerInstancesHasBeenSet() const { return m_containerInstancesHasBeenSet; } /** *

A list of up to 10 container instance IDs or full ARN entries.

*/ inline void SetContainerInstances(const Aws::Vector& value) { m_containerInstancesHasBeenSet = true; m_containerInstances = value; } /** *

A list of up to 10 container instance IDs or full ARN entries.

*/ inline void SetContainerInstances(Aws::Vector&& value) { m_containerInstancesHasBeenSet = true; m_containerInstances = std::move(value); } /** *

A list of up to 10 container instance IDs or full ARN entries.

*/ inline UpdateContainerInstancesStateRequest& WithContainerInstances(const Aws::Vector& value) { SetContainerInstances(value); return *this;} /** *

A list of up to 10 container instance IDs or full ARN entries.

*/ inline UpdateContainerInstancesStateRequest& WithContainerInstances(Aws::Vector&& value) { SetContainerInstances(std::move(value)); return *this;} /** *

A list of up to 10 container instance IDs or full ARN entries.

*/ inline UpdateContainerInstancesStateRequest& AddContainerInstances(const Aws::String& value) { m_containerInstancesHasBeenSet = true; m_containerInstances.push_back(value); return *this; } /** *

A list of up to 10 container instance IDs or full ARN entries.

*/ inline UpdateContainerInstancesStateRequest& AddContainerInstances(Aws::String&& value) { m_containerInstancesHasBeenSet = true; m_containerInstances.push_back(std::move(value)); return *this; } /** *

A list of up to 10 container instance IDs or full ARN entries.

*/ inline UpdateContainerInstancesStateRequest& AddContainerInstances(const char* value) { m_containerInstancesHasBeenSet = true; m_containerInstances.push_back(value); return *this; } /** *

The container instance state to update the container instance with. The only * valid values for this action are ACTIVE and DRAINING. * A container instance can only be updated to DRAINING status once it * has reached an ACTIVE state. If a container instance is in * REGISTERING, DEREGISTERING, or * REGISTRATION_FAILED state you can describe the container instance * but can't update the container instance state.

*/ inline const ContainerInstanceStatus& GetStatus() const{ return m_status; } /** *

The container instance state to update the container instance with. The only * valid values for this action are ACTIVE and DRAINING. * A container instance can only be updated to DRAINING status once it * has reached an ACTIVE state. If a container instance is in * REGISTERING, DEREGISTERING, or * REGISTRATION_FAILED state you can describe the container instance * but can't update the container instance state.

*/ inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; } /** *

The container instance state to update the container instance with. The only * valid values for this action are ACTIVE and DRAINING. * A container instance can only be updated to DRAINING status once it * has reached an ACTIVE state. If a container instance is in * REGISTERING, DEREGISTERING, or * REGISTRATION_FAILED state you can describe the container instance * but can't update the container instance state.

*/ inline void SetStatus(const ContainerInstanceStatus& value) { m_statusHasBeenSet = true; m_status = value; } /** *

The container instance state to update the container instance with. The only * valid values for this action are ACTIVE and DRAINING. * A container instance can only be updated to DRAINING status once it * has reached an ACTIVE state. If a container instance is in * REGISTERING, DEREGISTERING, or * REGISTRATION_FAILED state you can describe the container instance * but can't update the container instance state.

*/ inline void SetStatus(ContainerInstanceStatus&& value) { m_statusHasBeenSet = true; m_status = std::move(value); } /** *

The container instance state to update the container instance with. The only * valid values for this action are ACTIVE and DRAINING. * A container instance can only be updated to DRAINING status once it * has reached an ACTIVE state. If a container instance is in * REGISTERING, DEREGISTERING, or * REGISTRATION_FAILED state you can describe the container instance * but can't update the container instance state.

*/ inline UpdateContainerInstancesStateRequest& WithStatus(const ContainerInstanceStatus& value) { SetStatus(value); return *this;} /** *

The container instance state to update the container instance with. The only * valid values for this action are ACTIVE and DRAINING. * A container instance can only be updated to DRAINING status once it * has reached an ACTIVE state. If a container instance is in * REGISTERING, DEREGISTERING, or * REGISTRATION_FAILED state you can describe the container instance * but can't update the container instance state.

*/ inline UpdateContainerInstancesStateRequest& WithStatus(ContainerInstanceStatus&& value) { SetStatus(std::move(value)); return *this;} private: Aws::String m_cluster; bool m_clusterHasBeenSet = false; Aws::Vector m_containerInstances; bool m_containerInstancesHasBeenSet = false; ContainerInstanceStatus m_status; bool m_statusHasBeenSet = false; }; } // namespace Model } // namespace ECS } // namespace Aws