AWS SDK for C++  1.9.108
AWS SDK for C++
InstanceState.h
Go to the documentation of this file.
1 
6 #pragma once
7 #include <aws/ec2/EC2_EXPORTS.h>
10 #include <utility>
11 
12 namespace Aws
13 {
14 namespace Utils
15 {
16 namespace Xml
17 {
18  class XmlNode;
19 } // namespace Xml
20 } // namespace Utils
21 namespace EC2
22 {
23 namespace Model
24 {
25 
32  {
33  public:
37 
38  void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
39  void OutputToStream(Aws::OStream& oStream, const char* location) const;
40 
41 
57  inline int GetCode() const{ return m_code; }
58 
74  inline bool CodeHasBeenSet() const { return m_codeHasBeenSet; }
75 
91  inline void SetCode(int value) { m_codeHasBeenSet = true; m_code = value; }
92 
108  inline InstanceState& WithCode(int value) { SetCode(value); return *this;}
109 
110 
114  inline const InstanceStateName& GetName() const{ return m_name; }
115 
119  inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
120 
124  inline void SetName(const InstanceStateName& value) { m_nameHasBeenSet = true; m_name = value; }
125 
129  inline void SetName(InstanceStateName&& value) { m_nameHasBeenSet = true; m_name = std::move(value); }
130 
134  inline InstanceState& WithName(const InstanceStateName& value) { SetName(value); return *this;}
135 
139  inline InstanceState& WithName(InstanceStateName&& value) { SetName(std::move(value)); return *this;}
140 
141  private:
142 
143  int m_code;
144  bool m_codeHasBeenSet;
145 
146  InstanceStateName m_name;
147  bool m_nameHasBeenSet;
148  };
149 
150 } // namespace Model
151 } // namespace EC2
152 } // namespace Aws
Aws::EC2::Model::InstanceState::SetName
void SetName(const InstanceStateName &value)
Definition: InstanceState.h:124
Aws::EC2::Model::InstanceState::GetCode
int GetCode() const
Definition: InstanceState.h:57
AWS_EC2_API
#define AWS_EC2_API
Definition: EC2_EXPORTS.h:28
Aws::EC2::Model::InstanceState::CodeHasBeenSet
bool CodeHasBeenSet() const
Definition: InstanceState.h:74
AWSStreamFwd.h
Aws::EC2::Model::InstanceState
Definition: InstanceState.h:32
Aws::EC2::Model::InstanceState::InstanceState
InstanceState(const Aws::Utils::Xml::XmlNode &xmlNode)
Aws::EC2::Model::InstanceState::WithCode
InstanceState & WithCode(int value)
Definition: InstanceState.h:108
Aws::OStream
std::basic_ostream< char, std::char_traits< char > > OStream
Definition: AWSStreamFwd.h:21
Aws::EC2::Model::InstanceState::WithName
InstanceState & WithName(InstanceStateName &&value)
Definition: InstanceState.h:139
Aws::EC2::Model::InstanceState::SetName
void SetName(InstanceStateName &&value)
Definition: InstanceState.h:129
Aws::Utils::Xml::XmlNode
Definition: XmlSerializer.h:53
Aws::EC2::Model::InstanceStateName
InstanceStateName
Definition: InstanceStateName.h:17
Aws::EC2::Model::InstanceState::SetCode
void SetCode(int value)
Definition: InstanceState.h:91
Aws::EC2::Model::InstanceState::OutputToStream
void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
Aws::EC2::Model::InstanceState::WithName
InstanceState & WithName(const InstanceStateName &value)
Definition: InstanceState.h:134
Aws::EC2::Model::InstanceState::OutputToStream
void OutputToStream(Aws::OStream &oStream, const char *location) const
Aws::EC2::Model::InstanceState::InstanceState
InstanceState()
Aws
Definition: AccessManagementClient.h:15
Aws::EC2::Model::InstanceState::GetName
const InstanceStateName & GetName() const
Definition: InstanceState.h:114
Aws::EC2::Model::InstanceState::operator=
InstanceState & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
index
int index
Definition: cJSON.h:181
EC2_EXPORTS.h
Aws::EC2::Model::InstanceState::NameHasBeenSet
bool NameHasBeenSet() const
Definition: InstanceState.h:119
InstanceStateName.h