1 /** 2 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 * SPDX-License-Identifier: Apache-2.0. 4 */ 5 6 #pragma once 7 #include <aws/servicediscovery/ServiceDiscovery_EXPORTS.h> 8 #include <aws/core/utils/memory/stl/AWSString.h> 9 #include <aws/servicediscovery/model/OperationStatus.h> 10 #include <utility> 11 12 namespace Aws 13 { 14 namespace Utils 15 { 16 namespace Json 17 { 18 class JsonValue; 19 class JsonView; 20 } // namespace Json 21 } // namespace Utils 22 namespace ServiceDiscovery 23 { 24 namespace Model 25 { 26 27 /** 28 * <p>A complex type that contains information about an operation that matches the 29 * criteria that you specified in a <a 30 * href="https://docs.aws.amazon.com/cloud-map/latest/api/API_ListOperations.html">ListOperations</a> 31 * request.</p><p><h3>See Also:</h3> <a 32 * href="http://docs.aws.amazon.com/goto/WebAPI/servicediscovery-2017-03-14/OperationSummary">AWS 33 * API Reference</a></p> 34 */ 35 class AWS_SERVICEDISCOVERY_API OperationSummary 36 { 37 public: 38 OperationSummary(); 39 OperationSummary(Aws::Utils::Json::JsonView jsonValue); 40 OperationSummary& operator=(Aws::Utils::Json::JsonView jsonValue); 41 Aws::Utils::Json::JsonValue Jsonize() const; 42 43 44 /** 45 * <p>The ID for an operation.</p> 46 */ GetId()47 inline const Aws::String& GetId() const{ return m_id; } 48 49 /** 50 * <p>The ID for an operation.</p> 51 */ IdHasBeenSet()52 inline bool IdHasBeenSet() const { return m_idHasBeenSet; } 53 54 /** 55 * <p>The ID for an operation.</p> 56 */ SetId(const Aws::String & value)57 inline void SetId(const Aws::String& value) { m_idHasBeenSet = true; m_id = value; } 58 59 /** 60 * <p>The ID for an operation.</p> 61 */ SetId(Aws::String && value)62 inline void SetId(Aws::String&& value) { m_idHasBeenSet = true; m_id = std::move(value); } 63 64 /** 65 * <p>The ID for an operation.</p> 66 */ SetId(const char * value)67 inline void SetId(const char* value) { m_idHasBeenSet = true; m_id.assign(value); } 68 69 /** 70 * <p>The ID for an operation.</p> 71 */ WithId(const Aws::String & value)72 inline OperationSummary& WithId(const Aws::String& value) { SetId(value); return *this;} 73 74 /** 75 * <p>The ID for an operation.</p> 76 */ WithId(Aws::String && value)77 inline OperationSummary& WithId(Aws::String&& value) { SetId(std::move(value)); return *this;} 78 79 /** 80 * <p>The ID for an operation.</p> 81 */ WithId(const char * value)82 inline OperationSummary& WithId(const char* value) { SetId(value); return *this;} 83 84 85 /** 86 * <p>The status of the operation. Values include the following:</p> <ul> <li> <p> 87 * <b>SUBMITTED</b>: This is the initial state immediately after you submit a 88 * request.</p> </li> <li> <p> <b>PENDING</b>: Cloud Map is performing the 89 * operation.</p> </li> <li> <p> <b>SUCCESS</b>: The operation succeeded.</p> </li> 90 * <li> <p> <b>FAIL</b>: The operation failed. For the failure reason, see 91 * <code>ErrorMessage</code>.</p> </li> </ul> 92 */ GetStatus()93 inline const OperationStatus& GetStatus() const{ return m_status; } 94 95 /** 96 * <p>The status of the operation. Values include the following:</p> <ul> <li> <p> 97 * <b>SUBMITTED</b>: This is the initial state immediately after you submit a 98 * request.</p> </li> <li> <p> <b>PENDING</b>: Cloud Map is performing the 99 * operation.</p> </li> <li> <p> <b>SUCCESS</b>: The operation succeeded.</p> </li> 100 * <li> <p> <b>FAIL</b>: The operation failed. For the failure reason, see 101 * <code>ErrorMessage</code>.</p> </li> </ul> 102 */ StatusHasBeenSet()103 inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; } 104 105 /** 106 * <p>The status of the operation. Values include the following:</p> <ul> <li> <p> 107 * <b>SUBMITTED</b>: This is the initial state immediately after you submit a 108 * request.</p> </li> <li> <p> <b>PENDING</b>: Cloud Map is performing the 109 * operation.</p> </li> <li> <p> <b>SUCCESS</b>: The operation succeeded.</p> </li> 110 * <li> <p> <b>FAIL</b>: The operation failed. For the failure reason, see 111 * <code>ErrorMessage</code>.</p> </li> </ul> 112 */ SetStatus(const OperationStatus & value)113 inline void SetStatus(const OperationStatus& value) { m_statusHasBeenSet = true; m_status = value; } 114 115 /** 116 * <p>The status of the operation. Values include the following:</p> <ul> <li> <p> 117 * <b>SUBMITTED</b>: This is the initial state immediately after you submit a 118 * request.</p> </li> <li> <p> <b>PENDING</b>: Cloud Map is performing the 119 * operation.</p> </li> <li> <p> <b>SUCCESS</b>: The operation succeeded.</p> </li> 120 * <li> <p> <b>FAIL</b>: The operation failed. For the failure reason, see 121 * <code>ErrorMessage</code>.</p> </li> </ul> 122 */ SetStatus(OperationStatus && value)123 inline void SetStatus(OperationStatus&& value) { m_statusHasBeenSet = true; m_status = std::move(value); } 124 125 /** 126 * <p>The status of the operation. Values include the following:</p> <ul> <li> <p> 127 * <b>SUBMITTED</b>: This is the initial state immediately after you submit a 128 * request.</p> </li> <li> <p> <b>PENDING</b>: Cloud Map is performing the 129 * operation.</p> </li> <li> <p> <b>SUCCESS</b>: The operation succeeded.</p> </li> 130 * <li> <p> <b>FAIL</b>: The operation failed. For the failure reason, see 131 * <code>ErrorMessage</code>.</p> </li> </ul> 132 */ WithStatus(const OperationStatus & value)133 inline OperationSummary& WithStatus(const OperationStatus& value) { SetStatus(value); return *this;} 134 135 /** 136 * <p>The status of the operation. Values include the following:</p> <ul> <li> <p> 137 * <b>SUBMITTED</b>: This is the initial state immediately after you submit a 138 * request.</p> </li> <li> <p> <b>PENDING</b>: Cloud Map is performing the 139 * operation.</p> </li> <li> <p> <b>SUCCESS</b>: The operation succeeded.</p> </li> 140 * <li> <p> <b>FAIL</b>: The operation failed. For the failure reason, see 141 * <code>ErrorMessage</code>.</p> </li> </ul> 142 */ WithStatus(OperationStatus && value)143 inline OperationSummary& WithStatus(OperationStatus&& value) { SetStatus(std::move(value)); return *this;} 144 145 private: 146 147 Aws::String m_id; 148 bool m_idHasBeenSet; 149 150 OperationStatus m_status; 151 bool m_statusHasBeenSet; 152 }; 153 154 } // namespace Model 155 } // namespace ServiceDiscovery 156 } // namespace Aws 157