AWS SDK for C++

AWS SDK for C++ Version 1.11.717

Loading...
Searching...
No Matches
DetachVolumeResponse.h
1
6#pragma once
7#include <aws/core/utils/DateTime.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/ec2/EC2_EXPORTS.h>
10#include <aws/ec2/model/ResponseMetadata.h>
11#include <aws/ec2/model/VolumeAttachmentState.h>
12
13#include <utility>
14
15namespace Aws {
16template <typename RESULT_TYPE>
17class AmazonWebServiceResult;
18
19namespace Utils {
20namespace Xml {
21class XmlDocument;
22} // namespace Xml
23} // namespace Utils
24namespace EC2 {
25namespace Model {
32 public:
33 AWS_EC2_API DetachVolumeResponse() = default;
36
38
41 inline bool GetDeleteOnTermination() const { return m_deleteOnTermination; }
42 inline void SetDeleteOnTermination(bool value) {
43 m_deleteOnTerminationHasBeenSet = true;
44 m_deleteOnTermination = value;
45 }
48 return *this;
49 }
51
53
57 inline const Aws::String& GetAssociatedResource() const { return m_associatedResource; }
58 template <typename AssociatedResourceT = Aws::String>
59 void SetAssociatedResource(AssociatedResourceT&& value) {
60 m_associatedResourceHasBeenSet = true;
61 m_associatedResource = std::forward<AssociatedResourceT>(value);
62 }
63 template <typename AssociatedResourceT = Aws::String>
64 DetachVolumeResponse& WithAssociatedResource(AssociatedResourceT&& value) {
65 SetAssociatedResource(std::forward<AssociatedResourceT>(value));
66 return *this;
67 }
69
71
77 inline const Aws::String& GetInstanceOwningService() const { return m_instanceOwningService; }
78 template <typename InstanceOwningServiceT = Aws::String>
79 void SetInstanceOwningService(InstanceOwningServiceT&& value) {
80 m_instanceOwningServiceHasBeenSet = true;
81 m_instanceOwningService = std::forward<InstanceOwningServiceT>(value);
82 }
83 template <typename InstanceOwningServiceT = Aws::String>
84 DetachVolumeResponse& WithInstanceOwningService(InstanceOwningServiceT&& value) {
85 SetInstanceOwningService(std::forward<InstanceOwningServiceT>(value));
86 return *this;
87 }
89
91
94 inline const Aws::String& GetVolumeId() const { return m_volumeId; }
95 template <typename VolumeIdT = Aws::String>
96 void SetVolumeId(VolumeIdT&& value) {
97 m_volumeIdHasBeenSet = true;
98 m_volumeId = std::forward<VolumeIdT>(value);
99 }
100 template <typename VolumeIdT = Aws::String>
101 DetachVolumeResponse& WithVolumeId(VolumeIdT&& value) {
102 SetVolumeId(std::forward<VolumeIdT>(value));
103 return *this;
104 }
106
108
112 inline const Aws::String& GetInstanceId() const { return m_instanceId; }
113 template <typename InstanceIdT = Aws::String>
114 void SetInstanceId(InstanceIdT&& value) {
115 m_instanceIdHasBeenSet = true;
116 m_instanceId = std::forward<InstanceIdT>(value);
117 }
118 template <typename InstanceIdT = Aws::String>
119 DetachVolumeResponse& WithInstanceId(InstanceIdT&& value) {
120 SetInstanceId(std::forward<InstanceIdT>(value));
121 return *this;
122 }
124
126
130 inline const Aws::String& GetDevice() const { return m_device; }
131 template <typename DeviceT = Aws::String>
132 void SetDevice(DeviceT&& value) {
133 m_deviceHasBeenSet = true;
134 m_device = std::forward<DeviceT>(value);
135 }
136 template <typename DeviceT = Aws::String>
138 SetDevice(std::forward<DeviceT>(value));
139 return *this;
140 }
142
144
147 inline VolumeAttachmentState GetState() const { return m_state; }
148 inline void SetState(VolumeAttachmentState value) {
149 m_stateHasBeenSet = true;
150 m_state = value;
151 }
153 SetState(value);
154 return *this;
155 }
157
159
162 inline const Aws::Utils::DateTime& GetAttachTime() const { return m_attachTime; }
163 template <typename AttachTimeT = Aws::Utils::DateTime>
164 void SetAttachTime(AttachTimeT&& value) {
165 m_attachTimeHasBeenSet = true;
166 m_attachTime = std::forward<AttachTimeT>(value);
167 }
168 template <typename AttachTimeT = Aws::Utils::DateTime>
169 DetachVolumeResponse& WithAttachTime(AttachTimeT&& value) {
170 SetAttachTime(std::forward<AttachTimeT>(value));
171 return *this;
172 }
174
176
177 inline const ResponseMetadata& GetResponseMetadata() const { return m_responseMetadata; }
178 template <typename ResponseMetadataT = ResponseMetadata>
179 void SetResponseMetadata(ResponseMetadataT&& value) {
180 m_responseMetadataHasBeenSet = true;
181 m_responseMetadata = std::forward<ResponseMetadataT>(value);
182 }
183 template <typename ResponseMetadataT = ResponseMetadata>
184 DetachVolumeResponse& WithResponseMetadata(ResponseMetadataT&& value) {
185 SetResponseMetadata(std::forward<ResponseMetadataT>(value));
186 return *this;
187 }
189 private:
190 bool m_deleteOnTermination{false};
191
192 Aws::String m_associatedResource;
193
194 Aws::String m_instanceOwningService;
195
196 Aws::String m_volumeId;
197
198 Aws::String m_instanceId;
199
200 Aws::String m_device;
201
203
204 Aws::Utils::DateTime m_attachTime{};
205
206 ResponseMetadata m_responseMetadata;
207 bool m_deleteOnTerminationHasBeenSet = false;
208 bool m_associatedResourceHasBeenSet = false;
209 bool m_instanceOwningServiceHasBeenSet = false;
210 bool m_volumeIdHasBeenSet = false;
211 bool m_instanceIdHasBeenSet = false;
212 bool m_deviceHasBeenSet = false;
213 bool m_stateHasBeenSet = false;
214 bool m_attachTimeHasBeenSet = false;
215 bool m_responseMetadataHasBeenSet = false;
216};
217
218} // namespace Model
219} // namespace EC2
220} // namespace Aws
DetachVolumeResponse & WithResponseMetadata(ResponseMetadataT &&value)
const Aws::String & GetVolumeId() const
VolumeAttachmentState GetState() const
const Aws::String & GetInstanceId() const
DetachVolumeResponse & WithAttachTime(AttachTimeT &&value)
void SetResponseMetadata(ResponseMetadataT &&value)
DetachVolumeResponse & WithDevice(DeviceT &&value)
DetachVolumeResponse & WithAssociatedResource(AssociatedResourceT &&value)
AWS_EC2_API DetachVolumeResponse()=default
DetachVolumeResponse & WithDeleteOnTermination(bool value)
void SetState(VolumeAttachmentState value)
const Aws::Utils::DateTime & GetAttachTime() const
AWS_EC2_API DetachVolumeResponse(const Aws::AmazonWebServiceResult< Aws::Utils::Xml::XmlDocument > &result)
DetachVolumeResponse & WithVolumeId(VolumeIdT &&value)
DetachVolumeResponse & WithState(VolumeAttachmentState value)
void SetInstanceOwningService(InstanceOwningServiceT &&value)
DetachVolumeResponse & WithInstanceId(InstanceIdT &&value)
const Aws::String & GetInstanceOwningService() const
const Aws::String & GetAssociatedResource() const
const ResponseMetadata & GetResponseMetadata() const
void SetAssociatedResource(AssociatedResourceT &&value)
DetachVolumeResponse & WithInstanceOwningService(InstanceOwningServiceT &&value)
AWS_EC2_API DetachVolumeResponse & operator=(const Aws::AmazonWebServiceResult< Aws::Utils::Xml::XmlDocument > &result)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Xml::XmlDocument XmlDocument