/** * 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 ServiceDiscovery { namespace Model { /** *

A complex type that contains information about a specified * operation.

See Also:

AWS * API Reference

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

The ID of the operation that you want to get information about.

*/ inline const Aws::String& GetId() const{ return m_id; } /** *

The ID of the operation that you want to get information about.

*/ inline bool IdHasBeenSet() const { return m_idHasBeenSet; } /** *

The ID of the operation that you want to get information about.

*/ inline void SetId(const Aws::String& value) { m_idHasBeenSet = true; m_id = value; } /** *

The ID of the operation that you want to get information about.

*/ inline void SetId(Aws::String&& value) { m_idHasBeenSet = true; m_id = std::move(value); } /** *

The ID of the operation that you want to get information about.

*/ inline void SetId(const char* value) { m_idHasBeenSet = true; m_id.assign(value); } /** *

The ID of the operation that you want to get information about.

*/ inline Operation& WithId(const Aws::String& value) { SetId(value); return *this;} /** *

The ID of the operation that you want to get information about.

*/ inline Operation& WithId(Aws::String&& value) { SetId(std::move(value)); return *this;} /** *

The ID of the operation that you want to get information about.

*/ inline Operation& WithId(const char* value) { SetId(value); return *this;} /** *

The name of the operation that's associated with the specified ID.

*/ inline const OperationType& GetType() const{ return m_type; } /** *

The name of the operation that's associated with the specified ID.

*/ inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; } /** *

The name of the operation that's associated with the specified ID.

*/ inline void SetType(const OperationType& value) { m_typeHasBeenSet = true; m_type = value; } /** *

The name of the operation that's associated with the specified ID.

*/ inline void SetType(OperationType&& value) { m_typeHasBeenSet = true; m_type = std::move(value); } /** *

The name of the operation that's associated with the specified ID.

*/ inline Operation& WithType(const OperationType& value) { SetType(value); return *this;} /** *

The name of the operation that's associated with the specified ID.

*/ inline Operation& WithType(OperationType&& value) { SetType(std::move(value)); return *this;} /** *

The status of the operation. Values include the following:

*
SUBMITTED

This is the initial state that occurs immediately * after you submit a request.

PENDING

Cloud Map is * performing the operation.

SUCCESS

The operation * succeeded.

FAIL

The operation failed. For the failure * reason, see ErrorMessage.

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

The status of the operation. Values include the following:

*
SUBMITTED

This is the initial state that occurs immediately * after you submit a request.

PENDING

Cloud Map is * performing the operation.

SUCCESS

The operation * succeeded.

FAIL

The operation failed. For the failure * reason, see ErrorMessage.

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

The status of the operation. Values include the following:

*
SUBMITTED

This is the initial state that occurs immediately * after you submit a request.

PENDING

Cloud Map is * performing the operation.

SUCCESS

The operation * succeeded.

FAIL

The operation failed. For the failure * reason, see ErrorMessage.

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

The status of the operation. Values include the following:

*
SUBMITTED

This is the initial state that occurs immediately * after you submit a request.

PENDING

Cloud Map is * performing the operation.

SUCCESS

The operation * succeeded.

FAIL

The operation failed. For the failure * reason, see ErrorMessage.

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

The status of the operation. Values include the following:

*
SUBMITTED

This is the initial state that occurs immediately * after you submit a request.

PENDING

Cloud Map is * performing the operation.

SUCCESS

The operation * succeeded.

FAIL

The operation failed. For the failure * reason, see ErrorMessage.

*/ inline Operation& WithStatus(const OperationStatus& value) { SetStatus(value); return *this;} /** *

The status of the operation. Values include the following:

*
SUBMITTED

This is the initial state that occurs immediately * after you submit a request.

PENDING

Cloud Map is * performing the operation.

SUCCESS

The operation * succeeded.

FAIL

The operation failed. For the failure * reason, see ErrorMessage.

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

If the value of Status is FAIL, the reason that the * operation failed.

*/ inline const Aws::String& GetErrorMessage() const{ return m_errorMessage; } /** *

If the value of Status is FAIL, the reason that the * operation failed.

*/ inline bool ErrorMessageHasBeenSet() const { return m_errorMessageHasBeenSet; } /** *

If the value of Status is FAIL, the reason that the * operation failed.

*/ inline void SetErrorMessage(const Aws::String& value) { m_errorMessageHasBeenSet = true; m_errorMessage = value; } /** *

If the value of Status is FAIL, the reason that the * operation failed.

*/ inline void SetErrorMessage(Aws::String&& value) { m_errorMessageHasBeenSet = true; m_errorMessage = std::move(value); } /** *

If the value of Status is FAIL, the reason that the * operation failed.

*/ inline void SetErrorMessage(const char* value) { m_errorMessageHasBeenSet = true; m_errorMessage.assign(value); } /** *

If the value of Status is FAIL, the reason that the * operation failed.

*/ inline Operation& WithErrorMessage(const Aws::String& value) { SetErrorMessage(value); return *this;} /** *

If the value of Status is FAIL, the reason that the * operation failed.

*/ inline Operation& WithErrorMessage(Aws::String&& value) { SetErrorMessage(std::move(value)); return *this;} /** *

If the value of Status is FAIL, the reason that the * operation failed.

*/ inline Operation& WithErrorMessage(const char* value) { SetErrorMessage(value); return *this;} /** *

The code associated with ErrorMessage. Values for * ErrorCode include the following:

  • * ACCESS_DENIED

  • * CANNOT_CREATE_HOSTED_ZONE

  • * EXPIRED_TOKEN

  • * HOSTED_ZONE_NOT_FOUND

  • * INTERNAL_FAILURE

  • * INVALID_CHANGE_BATCH

  • * THROTTLED_REQUEST

*/ inline const Aws::String& GetErrorCode() const{ return m_errorCode; } /** *

The code associated with ErrorMessage. Values for * ErrorCode include the following:

  • * ACCESS_DENIED

  • * CANNOT_CREATE_HOSTED_ZONE

  • * EXPIRED_TOKEN

  • * HOSTED_ZONE_NOT_FOUND

  • * INTERNAL_FAILURE

  • * INVALID_CHANGE_BATCH

  • * THROTTLED_REQUEST

*/ inline bool ErrorCodeHasBeenSet() const { return m_errorCodeHasBeenSet; } /** *

The code associated with ErrorMessage. Values for * ErrorCode include the following:

  • * ACCESS_DENIED

  • * CANNOT_CREATE_HOSTED_ZONE

  • * EXPIRED_TOKEN

  • * HOSTED_ZONE_NOT_FOUND

  • * INTERNAL_FAILURE

  • * INVALID_CHANGE_BATCH

  • * THROTTLED_REQUEST

*/ inline void SetErrorCode(const Aws::String& value) { m_errorCodeHasBeenSet = true; m_errorCode = value; } /** *

The code associated with ErrorMessage. Values for * ErrorCode include the following:

  • * ACCESS_DENIED

  • * CANNOT_CREATE_HOSTED_ZONE

  • * EXPIRED_TOKEN

  • * HOSTED_ZONE_NOT_FOUND

  • * INTERNAL_FAILURE

  • * INVALID_CHANGE_BATCH

  • * THROTTLED_REQUEST

*/ inline void SetErrorCode(Aws::String&& value) { m_errorCodeHasBeenSet = true; m_errorCode = std::move(value); } /** *

The code associated with ErrorMessage. Values for * ErrorCode include the following:

  • * ACCESS_DENIED

  • * CANNOT_CREATE_HOSTED_ZONE

  • * EXPIRED_TOKEN

  • * HOSTED_ZONE_NOT_FOUND

  • * INTERNAL_FAILURE

  • * INVALID_CHANGE_BATCH

  • * THROTTLED_REQUEST

*/ inline void SetErrorCode(const char* value) { m_errorCodeHasBeenSet = true; m_errorCode.assign(value); } /** *

The code associated with ErrorMessage. Values for * ErrorCode include the following:

  • * ACCESS_DENIED

  • * CANNOT_CREATE_HOSTED_ZONE

  • * EXPIRED_TOKEN

  • * HOSTED_ZONE_NOT_FOUND

  • * INTERNAL_FAILURE

  • * INVALID_CHANGE_BATCH

  • * THROTTLED_REQUEST

*/ inline Operation& WithErrorCode(const Aws::String& value) { SetErrorCode(value); return *this;} /** *

The code associated with ErrorMessage. Values for * ErrorCode include the following:

  • * ACCESS_DENIED

  • * CANNOT_CREATE_HOSTED_ZONE

  • * EXPIRED_TOKEN

  • * HOSTED_ZONE_NOT_FOUND

  • * INTERNAL_FAILURE

  • * INVALID_CHANGE_BATCH

  • * THROTTLED_REQUEST

*/ inline Operation& WithErrorCode(Aws::String&& value) { SetErrorCode(std::move(value)); return *this;} /** *

The code associated with ErrorMessage. Values for * ErrorCode include the following:

  • * ACCESS_DENIED

  • * CANNOT_CREATE_HOSTED_ZONE

  • * EXPIRED_TOKEN

  • * HOSTED_ZONE_NOT_FOUND

  • * INTERNAL_FAILURE

  • * INVALID_CHANGE_BATCH

  • * THROTTLED_REQUEST

*/ inline Operation& WithErrorCode(const char* value) { SetErrorCode(value); return *this;} /** *

The date and time that the request was submitted, in Unix date/time format * and Coordinated Universal Time (UTC). The value of CreateDate is * accurate to milliseconds. For example, the value 1516925490.087 * represents Friday, January 26, 2018 12:11:30.087 AM.

*/ inline const Aws::Utils::DateTime& GetCreateDate() const{ return m_createDate; } /** *

The date and time that the request was submitted, in Unix date/time format * and Coordinated Universal Time (UTC). The value of CreateDate is * accurate to milliseconds. For example, the value 1516925490.087 * represents Friday, January 26, 2018 12:11:30.087 AM.

*/ inline bool CreateDateHasBeenSet() const { return m_createDateHasBeenSet; } /** *

The date and time that the request was submitted, in Unix date/time format * and Coordinated Universal Time (UTC). The value of CreateDate is * accurate to milliseconds. For example, the value 1516925490.087 * represents Friday, January 26, 2018 12:11:30.087 AM.

*/ inline void SetCreateDate(const Aws::Utils::DateTime& value) { m_createDateHasBeenSet = true; m_createDate = value; } /** *

The date and time that the request was submitted, in Unix date/time format * and Coordinated Universal Time (UTC). The value of CreateDate is * accurate to milliseconds. For example, the value 1516925490.087 * represents Friday, January 26, 2018 12:11:30.087 AM.

*/ inline void SetCreateDate(Aws::Utils::DateTime&& value) { m_createDateHasBeenSet = true; m_createDate = std::move(value); } /** *

The date and time that the request was submitted, in Unix date/time format * and Coordinated Universal Time (UTC). The value of CreateDate is * accurate to milliseconds. For example, the value 1516925490.087 * represents Friday, January 26, 2018 12:11:30.087 AM.

*/ inline Operation& WithCreateDate(const Aws::Utils::DateTime& value) { SetCreateDate(value); return *this;} /** *

The date and time that the request was submitted, in Unix date/time format * and Coordinated Universal Time (UTC). The value of CreateDate is * accurate to milliseconds. For example, the value 1516925490.087 * represents Friday, January 26, 2018 12:11:30.087 AM.

*/ inline Operation& WithCreateDate(Aws::Utils::DateTime&& value) { SetCreateDate(std::move(value)); return *this;} /** *

The date and time that the value of Status changed to the * current value, in Unix date/time format and Coordinated Universal Time (UTC). * The value of UpdateDate is accurate to milliseconds. For example, * the value 1516925490.087 represents Friday, January 26, 2018 * 12:11:30.087 AM.

*/ inline const Aws::Utils::DateTime& GetUpdateDate() const{ return m_updateDate; } /** *

The date and time that the value of Status changed to the * current value, in Unix date/time format and Coordinated Universal Time (UTC). * The value of UpdateDate is accurate to milliseconds. For example, * the value 1516925490.087 represents Friday, January 26, 2018 * 12:11:30.087 AM.

*/ inline bool UpdateDateHasBeenSet() const { return m_updateDateHasBeenSet; } /** *

The date and time that the value of Status changed to the * current value, in Unix date/time format and Coordinated Universal Time (UTC). * The value of UpdateDate is accurate to milliseconds. For example, * the value 1516925490.087 represents Friday, January 26, 2018 * 12:11:30.087 AM.

*/ inline void SetUpdateDate(const Aws::Utils::DateTime& value) { m_updateDateHasBeenSet = true; m_updateDate = value; } /** *

The date and time that the value of Status changed to the * current value, in Unix date/time format and Coordinated Universal Time (UTC). * The value of UpdateDate is accurate to milliseconds. For example, * the value 1516925490.087 represents Friday, January 26, 2018 * 12:11:30.087 AM.

*/ inline void SetUpdateDate(Aws::Utils::DateTime&& value) { m_updateDateHasBeenSet = true; m_updateDate = std::move(value); } /** *

The date and time that the value of Status changed to the * current value, in Unix date/time format and Coordinated Universal Time (UTC). * The value of UpdateDate is accurate to milliseconds. For example, * the value 1516925490.087 represents Friday, January 26, 2018 * 12:11:30.087 AM.

*/ inline Operation& WithUpdateDate(const Aws::Utils::DateTime& value) { SetUpdateDate(value); return *this;} /** *

The date and time that the value of Status changed to the * current value, in Unix date/time format and Coordinated Universal Time (UTC). * The value of UpdateDate is accurate to milliseconds. For example, * the value 1516925490.087 represents Friday, January 26, 2018 * 12:11:30.087 AM.

*/ inline Operation& WithUpdateDate(Aws::Utils::DateTime&& value) { SetUpdateDate(std::move(value)); return *this;} /** *

The name of the target entity that's associated with the operation:

*
NAMESPACE

The namespace ID is returned in the * ResourceId property.

SERVICE

The service * ID is returned in the ResourceId property.

*
INSTANCE

The instance ID is returned in the * ResourceId property.

*/ inline const Aws::Map& GetTargets() const{ return m_targets; } /** *

The name of the target entity that's associated with the operation:

*
NAMESPACE

The namespace ID is returned in the * ResourceId property.

SERVICE

The service * ID is returned in the ResourceId property.

*
INSTANCE

The instance ID is returned in the * ResourceId property.

*/ inline bool TargetsHasBeenSet() const { return m_targetsHasBeenSet; } /** *

The name of the target entity that's associated with the operation:

*
NAMESPACE

The namespace ID is returned in the * ResourceId property.

SERVICE

The service * ID is returned in the ResourceId property.

*
INSTANCE

The instance ID is returned in the * ResourceId property.

*/ inline void SetTargets(const Aws::Map& value) { m_targetsHasBeenSet = true; m_targets = value; } /** *

The name of the target entity that's associated with the operation:

*
NAMESPACE

The namespace ID is returned in the * ResourceId property.

SERVICE

The service * ID is returned in the ResourceId property.

*
INSTANCE

The instance ID is returned in the * ResourceId property.

*/ inline void SetTargets(Aws::Map&& value) { m_targetsHasBeenSet = true; m_targets = std::move(value); } /** *

The name of the target entity that's associated with the operation:

*
NAMESPACE

The namespace ID is returned in the * ResourceId property.

SERVICE

The service * ID is returned in the ResourceId property.

*
INSTANCE

The instance ID is returned in the * ResourceId property.

*/ inline Operation& WithTargets(const Aws::Map& value) { SetTargets(value); return *this;} /** *

The name of the target entity that's associated with the operation:

*
NAMESPACE

The namespace ID is returned in the * ResourceId property.

SERVICE

The service * ID is returned in the ResourceId property.

*
INSTANCE

The instance ID is returned in the * ResourceId property.

*/ inline Operation& WithTargets(Aws::Map&& value) { SetTargets(std::move(value)); return *this;} /** *

The name of the target entity that's associated with the operation:

*
NAMESPACE

The namespace ID is returned in the * ResourceId property.

SERVICE

The service * ID is returned in the ResourceId property.

*
INSTANCE

The instance ID is returned in the * ResourceId property.

*/ inline Operation& AddTargets(const OperationTargetType& key, const Aws::String& value) { m_targetsHasBeenSet = true; m_targets.emplace(key, value); return *this; } /** *

The name of the target entity that's associated with the operation:

*
NAMESPACE

The namespace ID is returned in the * ResourceId property.

SERVICE

The service * ID is returned in the ResourceId property.

*
INSTANCE

The instance ID is returned in the * ResourceId property.

*/ inline Operation& AddTargets(OperationTargetType&& key, const Aws::String& value) { m_targetsHasBeenSet = true; m_targets.emplace(std::move(key), value); return *this; } /** *

The name of the target entity that's associated with the operation:

*
NAMESPACE

The namespace ID is returned in the * ResourceId property.

SERVICE

The service * ID is returned in the ResourceId property.

*
INSTANCE

The instance ID is returned in the * ResourceId property.

*/ inline Operation& AddTargets(const OperationTargetType& key, Aws::String&& value) { m_targetsHasBeenSet = true; m_targets.emplace(key, std::move(value)); return *this; } /** *

The name of the target entity that's associated with the operation:

*
NAMESPACE

The namespace ID is returned in the * ResourceId property.

SERVICE

The service * ID is returned in the ResourceId property.

*
INSTANCE

The instance ID is returned in the * ResourceId property.

*/ inline Operation& AddTargets(OperationTargetType&& key, Aws::String&& value) { m_targetsHasBeenSet = true; m_targets.emplace(std::move(key), std::move(value)); return *this; } /** *

The name of the target entity that's associated with the operation:

*
NAMESPACE

The namespace ID is returned in the * ResourceId property.

SERVICE

The service * ID is returned in the ResourceId property.

*
INSTANCE

The instance ID is returned in the * ResourceId property.

*/ inline Operation& AddTargets(OperationTargetType&& key, const char* value) { m_targetsHasBeenSet = true; m_targets.emplace(std::move(key), value); return *this; } /** *

The name of the target entity that's associated with the operation:

*
NAMESPACE

The namespace ID is returned in the * ResourceId property.

SERVICE

The service * ID is returned in the ResourceId property.

*
INSTANCE

The instance ID is returned in the * ResourceId property.

*/ inline Operation& AddTargets(const OperationTargetType& key, const char* value) { m_targetsHasBeenSet = true; m_targets.emplace(key, value); return *this; } private: Aws::String m_id; bool m_idHasBeenSet = false; OperationType m_type; bool m_typeHasBeenSet = false; OperationStatus m_status; bool m_statusHasBeenSet = false; Aws::String m_errorMessage; bool m_errorMessageHasBeenSet = false; Aws::String m_errorCode; bool m_errorCodeHasBeenSet = false; Aws::Utils::DateTime m_createDate; bool m_createDateHasBeenSet = false; Aws::Utils::DateTime m_updateDate; bool m_updateDateHasBeenSet = false; Aws::Map m_targets; bool m_targetsHasBeenSet = false; }; } // namespace Model } // namespace ServiceDiscovery } // namespace Aws