AWS SDK for C++  0.12.9
AWS SDK for C++
AttachVolumeResponse.h
Go to the documentation of this file.
1 /*
2 * Copyright 2010-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License").
5 * You may not use this file except in compliance with the License.
6 * A copy of the License is located at
7 *
8 * http://aws.amazon.com/apache2.0
9 *
10 * or in the "license" file accompanying this file. This file is distributed
11 * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12 * express or implied. See the License for the specific language governing
13 * permissions and limitations under the License.
14 */
15 #pragma once
16 #include <aws/ec2/EC2_EXPORTS.h>
21 
22 namespace Aws
23 {
24 template<typename RESULT_TYPE>
25 class AmazonWebServiceResult;
26 
27 namespace Utils
28 {
29 namespace Xml
30 {
31  class XmlDocument;
32 } // namespace Xml
33 } // namespace Utils
34 namespace EC2
35 {
36 namespace Model
37 {
42  {
43  public:
47 
51  inline const Aws::String& GetVolumeId() const{ return m_volumeId; }
52 
56  inline void SetVolumeId(const Aws::String& value) { m_volumeId = value; }
57 
61  inline void SetVolumeId(Aws::String&& value) { m_volumeId = value; }
62 
66  inline void SetVolumeId(const char* value) { m_volumeId.assign(value); }
67 
71  inline AttachVolumeResponse& WithVolumeId(const Aws::String& value) { SetVolumeId(value); return *this;}
72 
76  inline AttachVolumeResponse& WithVolumeId(Aws::String&& value) { SetVolumeId(value); return *this;}
77 
81  inline AttachVolumeResponse& WithVolumeId(const char* value) { SetVolumeId(value); return *this;}
82 
86  inline const Aws::String& GetInstanceId() const{ return m_instanceId; }
87 
91  inline void SetInstanceId(const Aws::String& value) { m_instanceId = value; }
92 
96  inline void SetInstanceId(Aws::String&& value) { m_instanceId = value; }
97 
101  inline void SetInstanceId(const char* value) { m_instanceId.assign(value); }
102 
106  inline AttachVolumeResponse& WithInstanceId(const Aws::String& value) { SetInstanceId(value); return *this;}
107 
111  inline AttachVolumeResponse& WithInstanceId(Aws::String&& value) { SetInstanceId(value); return *this;}
112 
116  inline AttachVolumeResponse& WithInstanceId(const char* value) { SetInstanceId(value); return *this;}
117 
121  inline const Aws::String& GetDevice() const{ return m_device; }
122 
126  inline void SetDevice(const Aws::String& value) { m_device = value; }
127 
131  inline void SetDevice(Aws::String&& value) { m_device = value; }
132 
136  inline void SetDevice(const char* value) { m_device.assign(value); }
137 
141  inline AttachVolumeResponse& WithDevice(const Aws::String& value) { SetDevice(value); return *this;}
142 
146  inline AttachVolumeResponse& WithDevice(Aws::String&& value) { SetDevice(value); return *this;}
147 
151  inline AttachVolumeResponse& WithDevice(const char* value) { SetDevice(value); return *this;}
152 
156  inline const VolumeAttachmentState& GetState() const{ return m_state; }
157 
161  inline void SetState(const VolumeAttachmentState& value) { m_state = value; }
162 
166  inline void SetState(VolumeAttachmentState&& value) { m_state = value; }
167 
171  inline AttachVolumeResponse& WithState(const VolumeAttachmentState& value) { SetState(value); return *this;}
172 
176  inline AttachVolumeResponse& WithState(VolumeAttachmentState&& value) { SetState(value); return *this;}
177 
181  inline const Aws::Utils::DateTime& GetAttachTime() const{ return m_attachTime; }
182 
186  inline void SetAttachTime(const Aws::Utils::DateTime& value) { m_attachTime = value; }
187 
191  inline void SetAttachTime(Aws::Utils::DateTime&& value) { m_attachTime = value; }
192 
196  inline AttachVolumeResponse& WithAttachTime(const Aws::Utils::DateTime& value) { SetAttachTime(value); return *this;}
197 
201  inline AttachVolumeResponse& WithAttachTime(Aws::Utils::DateTime&& value) { SetAttachTime(value); return *this;}
202 
206  inline bool GetDeleteOnTermination() const{ return m_deleteOnTermination; }
207 
211  inline void SetDeleteOnTermination(bool value) { m_deleteOnTermination = value; }
212 
216  inline AttachVolumeResponse& WithDeleteOnTermination(bool value) { SetDeleteOnTermination(value); return *this;}
217 
218 
219  inline const ResponseMetadata& GetResponseMetadata() const{ return m_responseMetadata; }
220 
221 
222  inline void SetResponseMetadata(const ResponseMetadata& value) { m_responseMetadata = value; }
223 
224 
225  inline void SetResponseMetadata(ResponseMetadata&& value) { m_responseMetadata = value; }
226 
227 
228  inline AttachVolumeResponse& WithResponseMetadata(const ResponseMetadata& value) { SetResponseMetadata(value); return *this;}
229 
230 
231  inline AttachVolumeResponse& WithResponseMetadata(ResponseMetadata&& value) { SetResponseMetadata(value); return *this;}
232 
233  private:
234  Aws::String m_volumeId;
235  Aws::String m_instanceId;
236  Aws::String m_device;
237  VolumeAttachmentState m_state;
238  Aws::Utils::DateTime m_attachTime;
239  bool m_deleteOnTermination;
240  ResponseMetadata m_responseMetadata;
241  };
242 
243 } // namespace Model
244 } // namespace EC2
245 } // namespace Aws
AttachVolumeResponse & WithAttachTime(const Aws::Utils::DateTime &value)
void SetAttachTime(const Aws::Utils::DateTime &value)
AttachVolumeResponse & WithDevice(const Aws::String &value)
void SetInstanceId(const Aws::String &value)
AttachVolumeResponse & WithVolumeId(Aws::String &&value)
const Aws::String & GetInstanceId() const
const Aws::String & GetDevice() const
AttachVolumeResponse & WithDevice(const char *value)
AttachVolumeResponse & WithInstanceId(const char *value)
void SetVolumeId(const Aws::String &value)
AttachVolumeResponse & WithResponseMetadata(const ResponseMetadata &value)
void SetResponseMetadata(const ResponseMetadata &value)
void SetState(const VolumeAttachmentState &value)
AttachVolumeResponse & WithInstanceId(const Aws::String &value)
const ResponseMetadata & GetResponseMetadata() const
void SetState(VolumeAttachmentState &&value)
AttachVolumeResponse & WithState(VolumeAttachmentState &&value)
AttachVolumeResponse & WithInstanceId(Aws::String &&value)
AttachVolumeResponse & WithVolumeId(const char *value)
void SetAttachTime(Aws::Utils::DateTime &&value)
AttachVolumeResponse & WithAttachTime(Aws::Utils::DateTime &&value)
const Aws::String & GetVolumeId() const
void SetResponseMetadata(ResponseMetadata &&value)
AttachVolumeResponse & WithDeleteOnTermination(bool value)
const VolumeAttachmentState & GetState() const
AttachVolumeResponse & WithDevice(Aws::String &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
void SetDevice(const Aws::String &value)
AttachVolumeResponse & WithResponseMetadata(ResponseMetadata &&value)
AttachVolumeResponse & WithVolumeId(const Aws::String &value)
#define AWS_EC2_API
Definition: EC2_EXPORTS.h:34
AttachVolumeResponse & WithState(const VolumeAttachmentState &value)
const Aws::Utils::DateTime & GetAttachTime() const
JSON (JavaScript Object Notation).