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

Information about an instance in a deployment.

See Also:

AWS * API Reference

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

The unique ID of a deployment.

*/ inline const Aws::String& GetDeploymentId() const{ return m_deploymentId; } /** *

The unique ID of a deployment.

*/ inline bool DeploymentIdHasBeenSet() const { return m_deploymentIdHasBeenSet; } /** *

The unique ID of a deployment.

*/ inline void SetDeploymentId(const Aws::String& value) { m_deploymentIdHasBeenSet = true; m_deploymentId = value; } /** *

The unique ID of a deployment.

*/ inline void SetDeploymentId(Aws::String&& value) { m_deploymentIdHasBeenSet = true; m_deploymentId = std::move(value); } /** *

The unique ID of a deployment.

*/ inline void SetDeploymentId(const char* value) { m_deploymentIdHasBeenSet = true; m_deploymentId.assign(value); } /** *

The unique ID of a deployment.

*/ inline InstanceSummary& WithDeploymentId(const Aws::String& value) { SetDeploymentId(value); return *this;} /** *

The unique ID of a deployment.

*/ inline InstanceSummary& WithDeploymentId(Aws::String&& value) { SetDeploymentId(std::move(value)); return *this;} /** *

The unique ID of a deployment.

*/ inline InstanceSummary& WithDeploymentId(const char* value) { SetDeploymentId(value); return *this;} /** *

The instance ID.

*/ inline const Aws::String& GetInstanceId() const{ return m_instanceId; } /** *

The instance ID.

*/ inline bool InstanceIdHasBeenSet() const { return m_instanceIdHasBeenSet; } /** *

The instance ID.

*/ inline void SetInstanceId(const Aws::String& value) { m_instanceIdHasBeenSet = true; m_instanceId = value; } /** *

The instance ID.

*/ inline void SetInstanceId(Aws::String&& value) { m_instanceIdHasBeenSet = true; m_instanceId = std::move(value); } /** *

The instance ID.

*/ inline void SetInstanceId(const char* value) { m_instanceIdHasBeenSet = true; m_instanceId.assign(value); } /** *

The instance ID.

*/ inline InstanceSummary& WithInstanceId(const Aws::String& value) { SetInstanceId(value); return *this;} /** *

The instance ID.

*/ inline InstanceSummary& WithInstanceId(Aws::String&& value) { SetInstanceId(std::move(value)); return *this;} /** *

The instance ID.

*/ inline InstanceSummary& WithInstanceId(const char* value) { SetInstanceId(value); return *this;} /** *

The deployment status for this instance:

  • * Pending: The deployment is pending for this instance.

  • *
  • In Progress: The deployment is in progress for this * instance.

  • Succeeded: The deployment has * succeeded for this instance.

  • Failed: The * deployment has failed for this instance.

  • * Skipped: The deployment has been skipped for this instance.

    *
  • Unknown: The deployment status is unknown for this * instance.

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

The deployment status for this instance:

  • * Pending: The deployment is pending for this instance.

  • *
  • In Progress: The deployment is in progress for this * instance.

  • Succeeded: The deployment has * succeeded for this instance.

  • Failed: The * deployment has failed for this instance.

  • * Skipped: The deployment has been skipped for this instance.

    *
  • Unknown: The deployment status is unknown for this * instance.

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

The deployment status for this instance:

  • * Pending: The deployment is pending for this instance.

  • *
  • In Progress: The deployment is in progress for this * instance.

  • Succeeded: The deployment has * succeeded for this instance.

  • Failed: The * deployment has failed for this instance.

  • * Skipped: The deployment has been skipped for this instance.

    *
  • Unknown: The deployment status is unknown for this * instance.

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

The deployment status for this instance:

  • * Pending: The deployment is pending for this instance.

  • *
  • In Progress: The deployment is in progress for this * instance.

  • Succeeded: The deployment has * succeeded for this instance.

  • Failed: The * deployment has failed for this instance.

  • * Skipped: The deployment has been skipped for this instance.

    *
  • Unknown: The deployment status is unknown for this * instance.

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

The deployment status for this instance:

  • * Pending: The deployment is pending for this instance.

  • *
  • In Progress: The deployment is in progress for this * instance.

  • Succeeded: The deployment has * succeeded for this instance.

  • Failed: The * deployment has failed for this instance.

  • * Skipped: The deployment has been skipped for this instance.

    *
  • Unknown: The deployment status is unknown for this * instance.

*/ inline InstanceSummary& WithStatus(const InstanceStatus& value) { SetStatus(value); return *this;} /** *

The deployment status for this instance:

  • * Pending: The deployment is pending for this instance.

  • *
  • In Progress: The deployment is in progress for this * instance.

  • Succeeded: The deployment has * succeeded for this instance.

  • Failed: The * deployment has failed for this instance.

  • * Skipped: The deployment has been skipped for this instance.

    *
  • Unknown: The deployment status is unknown for this * instance.

*/ inline InstanceSummary& WithStatus(InstanceStatus&& value) { SetStatus(std::move(value)); return *this;} /** *

A timestamp that indicates when the instance information was last * updated.

*/ inline const Aws::Utils::DateTime& GetLastUpdatedAt() const{ return m_lastUpdatedAt; } /** *

A timestamp that indicates when the instance information was last * updated.

*/ inline bool LastUpdatedAtHasBeenSet() const { return m_lastUpdatedAtHasBeenSet; } /** *

A timestamp that indicates when the instance information was last * updated.

*/ inline void SetLastUpdatedAt(const Aws::Utils::DateTime& value) { m_lastUpdatedAtHasBeenSet = true; m_lastUpdatedAt = value; } /** *

A timestamp that indicates when the instance information was last * updated.

*/ inline void SetLastUpdatedAt(Aws::Utils::DateTime&& value) { m_lastUpdatedAtHasBeenSet = true; m_lastUpdatedAt = std::move(value); } /** *

A timestamp that indicates when the instance information was last * updated.

*/ inline InstanceSummary& WithLastUpdatedAt(const Aws::Utils::DateTime& value) { SetLastUpdatedAt(value); return *this;} /** *

A timestamp that indicates when the instance information was last * updated.

*/ inline InstanceSummary& WithLastUpdatedAt(Aws::Utils::DateTime&& value) { SetLastUpdatedAt(std::move(value)); return *this;} /** *

A list of lifecycle events for this instance.

*/ inline const Aws::Vector& GetLifecycleEvents() const{ return m_lifecycleEvents; } /** *

A list of lifecycle events for this instance.

*/ inline bool LifecycleEventsHasBeenSet() const { return m_lifecycleEventsHasBeenSet; } /** *

A list of lifecycle events for this instance.

*/ inline void SetLifecycleEvents(const Aws::Vector& value) { m_lifecycleEventsHasBeenSet = true; m_lifecycleEvents = value; } /** *

A list of lifecycle events for this instance.

*/ inline void SetLifecycleEvents(Aws::Vector&& value) { m_lifecycleEventsHasBeenSet = true; m_lifecycleEvents = std::move(value); } /** *

A list of lifecycle events for this instance.

*/ inline InstanceSummary& WithLifecycleEvents(const Aws::Vector& value) { SetLifecycleEvents(value); return *this;} /** *

A list of lifecycle events for this instance.

*/ inline InstanceSummary& WithLifecycleEvents(Aws::Vector&& value) { SetLifecycleEvents(std::move(value)); return *this;} /** *

A list of lifecycle events for this instance.

*/ inline InstanceSummary& AddLifecycleEvents(const LifecycleEvent& value) { m_lifecycleEventsHasBeenSet = true; m_lifecycleEvents.push_back(value); return *this; } /** *

A list of lifecycle events for this instance.

*/ inline InstanceSummary& AddLifecycleEvents(LifecycleEvent&& value) { m_lifecycleEventsHasBeenSet = true; m_lifecycleEvents.push_back(std::move(value)); return *this; } /** *

Information about which environment an instance belongs to in a blue/green * deployment.

  • BLUE: The instance is part of the original * environment.

  • GREEN: The instance is part of the replacement * environment.

*/ inline const InstanceType& GetInstanceType() const{ return m_instanceType; } /** *

Information about which environment an instance belongs to in a blue/green * deployment.

  • BLUE: The instance is part of the original * environment.

  • GREEN: The instance is part of the replacement * environment.

*/ inline bool InstanceTypeHasBeenSet() const { return m_instanceTypeHasBeenSet; } /** *

Information about which environment an instance belongs to in a blue/green * deployment.

  • BLUE: The instance is part of the original * environment.

  • GREEN: The instance is part of the replacement * environment.

*/ inline void SetInstanceType(const InstanceType& value) { m_instanceTypeHasBeenSet = true; m_instanceType = value; } /** *

Information about which environment an instance belongs to in a blue/green * deployment.

  • BLUE: The instance is part of the original * environment.

  • GREEN: The instance is part of the replacement * environment.

*/ inline void SetInstanceType(InstanceType&& value) { m_instanceTypeHasBeenSet = true; m_instanceType = std::move(value); } /** *

Information about which environment an instance belongs to in a blue/green * deployment.

  • BLUE: The instance is part of the original * environment.

  • GREEN: The instance is part of the replacement * environment.

*/ inline InstanceSummary& WithInstanceType(const InstanceType& value) { SetInstanceType(value); return *this;} /** *

Information about which environment an instance belongs to in a blue/green * deployment.

  • BLUE: The instance is part of the original * environment.

  • GREEN: The instance is part of the replacement * environment.

*/ inline InstanceSummary& WithInstanceType(InstanceType&& value) { SetInstanceType(std::move(value)); return *this;} private: Aws::String m_deploymentId; bool m_deploymentIdHasBeenSet = false; Aws::String m_instanceId; bool m_instanceIdHasBeenSet = false; InstanceStatus m_status; bool m_statusHasBeenSet = false; Aws::Utils::DateTime m_lastUpdatedAt; bool m_lastUpdatedAtHasBeenSet = false; Aws::Vector m_lifecycleEvents; bool m_lifecycleEventsHasBeenSet = false; InstanceType m_instanceType; bool m_instanceTypeHasBeenSet = false; }; } // namespace Model } // namespace CodeDeploy } // namespace Aws