AWS SDK for C++

AWS SDK for C++ Version 1.11.440

Loading...
Searching...
No Matches
PlacementGroup.h
1
6#pragma once
7#include <aws/ec2/EC2_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSStreamFwd.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/ec2/model/PlacementGroupState.h>
11#include <aws/ec2/model/PlacementStrategy.h>
12#include <aws/core/utils/memory/stl/AWSVector.h>
13#include <aws/ec2/model/SpreadLevel.h>
14#include <aws/ec2/model/Tag.h>
15#include <utility>
16
17namespace Aws
18{
19namespace Utils
20{
21namespace Xml
22{
23 class XmlNode;
24} // namespace Xml
25} // namespace Utils
26namespace EC2
27{
28namespace Model
29{
30
37 {
38 public:
39 AWS_EC2_API PlacementGroup();
40 AWS_EC2_API PlacementGroup(const Aws::Utils::Xml::XmlNode& xmlNode);
42
43 AWS_EC2_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
44 AWS_EC2_API void OutputToStream(Aws::OStream& oStream, const char* location) const;
45
46
48
51 inline const Aws::String& GetGroupName() const{ return m_groupName; }
52 inline bool GroupNameHasBeenSet() const { return m_groupNameHasBeenSet; }
53 inline void SetGroupName(const Aws::String& value) { m_groupNameHasBeenSet = true; m_groupName = value; }
54 inline void SetGroupName(Aws::String&& value) { m_groupNameHasBeenSet = true; m_groupName = std::move(value); }
55 inline void SetGroupName(const char* value) { m_groupNameHasBeenSet = true; m_groupName.assign(value); }
56 inline PlacementGroup& WithGroupName(const Aws::String& value) { SetGroupName(value); return *this;}
57 inline PlacementGroup& WithGroupName(Aws::String&& value) { SetGroupName(std::move(value)); return *this;}
58 inline PlacementGroup& WithGroupName(const char* value) { SetGroupName(value); return *this;}
60
62
65 inline const PlacementGroupState& GetState() const{ return m_state; }
66 inline bool StateHasBeenSet() const { return m_stateHasBeenSet; }
67 inline void SetState(const PlacementGroupState& value) { m_stateHasBeenSet = true; m_state = value; }
68 inline void SetState(PlacementGroupState&& value) { m_stateHasBeenSet = true; m_state = std::move(value); }
69 inline PlacementGroup& WithState(const PlacementGroupState& value) { SetState(value); return *this;}
70 inline PlacementGroup& WithState(PlacementGroupState&& value) { SetState(std::move(value)); return *this;}
72
74
77 inline const PlacementStrategy& GetStrategy() const{ return m_strategy; }
78 inline bool StrategyHasBeenSet() const { return m_strategyHasBeenSet; }
79 inline void SetStrategy(const PlacementStrategy& value) { m_strategyHasBeenSet = true; m_strategy = value; }
80 inline void SetStrategy(PlacementStrategy&& value) { m_strategyHasBeenSet = true; m_strategy = std::move(value); }
81 inline PlacementGroup& WithStrategy(const PlacementStrategy& value) { SetStrategy(value); return *this;}
82 inline PlacementGroup& WithStrategy(PlacementStrategy&& value) { SetStrategy(std::move(value)); return *this;}
84
86
90 inline int GetPartitionCount() const{ return m_partitionCount; }
91 inline bool PartitionCountHasBeenSet() const { return m_partitionCountHasBeenSet; }
92 inline void SetPartitionCount(int value) { m_partitionCountHasBeenSet = true; m_partitionCount = value; }
93 inline PlacementGroup& WithPartitionCount(int value) { SetPartitionCount(value); return *this;}
95
97
100 inline const Aws::String& GetGroupId() const{ return m_groupId; }
101 inline bool GroupIdHasBeenSet() const { return m_groupIdHasBeenSet; }
102 inline void SetGroupId(const Aws::String& value) { m_groupIdHasBeenSet = true; m_groupId = value; }
103 inline void SetGroupId(Aws::String&& value) { m_groupIdHasBeenSet = true; m_groupId = std::move(value); }
104 inline void SetGroupId(const char* value) { m_groupIdHasBeenSet = true; m_groupId.assign(value); }
105 inline PlacementGroup& WithGroupId(const Aws::String& value) { SetGroupId(value); return *this;}
106 inline PlacementGroup& WithGroupId(Aws::String&& value) { SetGroupId(std::move(value)); return *this;}
107 inline PlacementGroup& WithGroupId(const char* value) { SetGroupId(value); return *this;}
109
111
114 inline const Aws::Vector<Tag>& GetTags() const{ return m_tags; }
115 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
116 inline void SetTags(const Aws::Vector<Tag>& value) { m_tagsHasBeenSet = true; m_tags = value; }
117 inline void SetTags(Aws::Vector<Tag>&& value) { m_tagsHasBeenSet = true; m_tags = std::move(value); }
118 inline PlacementGroup& WithTags(const Aws::Vector<Tag>& value) { SetTags(value); return *this;}
119 inline PlacementGroup& WithTags(Aws::Vector<Tag>&& value) { SetTags(std::move(value)); return *this;}
120 inline PlacementGroup& AddTags(const Tag& value) { m_tagsHasBeenSet = true; m_tags.push_back(value); return *this; }
121 inline PlacementGroup& AddTags(Tag&& value) { m_tagsHasBeenSet = true; m_tags.push_back(std::move(value)); return *this; }
123
125
128 inline const Aws::String& GetGroupArn() const{ return m_groupArn; }
129 inline bool GroupArnHasBeenSet() const { return m_groupArnHasBeenSet; }
130 inline void SetGroupArn(const Aws::String& value) { m_groupArnHasBeenSet = true; m_groupArn = value; }
131 inline void SetGroupArn(Aws::String&& value) { m_groupArnHasBeenSet = true; m_groupArn = std::move(value); }
132 inline void SetGroupArn(const char* value) { m_groupArnHasBeenSet = true; m_groupArn.assign(value); }
133 inline PlacementGroup& WithGroupArn(const Aws::String& value) { SetGroupArn(value); return *this;}
134 inline PlacementGroup& WithGroupArn(Aws::String&& value) { SetGroupArn(std::move(value)); return *this;}
135 inline PlacementGroup& WithGroupArn(const char* value) { SetGroupArn(value); return *this;}
137
139
143 inline const SpreadLevel& GetSpreadLevel() const{ return m_spreadLevel; }
144 inline bool SpreadLevelHasBeenSet() const { return m_spreadLevelHasBeenSet; }
145 inline void SetSpreadLevel(const SpreadLevel& value) { m_spreadLevelHasBeenSet = true; m_spreadLevel = value; }
146 inline void SetSpreadLevel(SpreadLevel&& value) { m_spreadLevelHasBeenSet = true; m_spreadLevel = std::move(value); }
147 inline PlacementGroup& WithSpreadLevel(const SpreadLevel& value) { SetSpreadLevel(value); return *this;}
148 inline PlacementGroup& WithSpreadLevel(SpreadLevel&& value) { SetSpreadLevel(std::move(value)); return *this;}
150 private:
151
152 Aws::String m_groupName;
153 bool m_groupNameHasBeenSet = false;
154
155 PlacementGroupState m_state;
156 bool m_stateHasBeenSet = false;
157
158 PlacementStrategy m_strategy;
159 bool m_strategyHasBeenSet = false;
160
161 int m_partitionCount;
162 bool m_partitionCountHasBeenSet = false;
163
164 Aws::String m_groupId;
165 bool m_groupIdHasBeenSet = false;
166
167 Aws::Vector<Tag> m_tags;
168 bool m_tagsHasBeenSet = false;
169
170 Aws::String m_groupArn;
171 bool m_groupArnHasBeenSet = false;
172
173 SpreadLevel m_spreadLevel;
174 bool m_spreadLevelHasBeenSet = false;
175 };
176
177} // namespace Model
178} // namespace EC2
179} // namespace Aws
void SetGroupId(Aws::String &&value)
PlacementGroup & AddTags(Tag &&value)
void SetGroupId(const Aws::String &value)
const Aws::String & GetGroupId() const
void SetGroupArn(Aws::String &&value)
PlacementGroup & WithState(PlacementGroupState &&value)
PlacementGroup & WithTags(const Aws::Vector< Tag > &value)
PlacementGroup & WithGroupId(Aws::String &&value)
const Aws::Vector< Tag > & GetTags() const
void SetGroupName(Aws::String &&value)
void SetStrategy(PlacementStrategy &&value)
AWS_EC2_API void OutputToStream(Aws::OStream &oStream, const char *location) const
void SetTags(Aws::Vector< Tag > &&value)
void SetGroupArn(const char *value)
PlacementGroup & WithSpreadLevel(const SpreadLevel &value)
void SetSpreadLevel(SpreadLevel &&value)
void SetGroupName(const Aws::String &value)
void SetGroupArn(const Aws::String &value)
PlacementGroup & WithGroupArn(const Aws::String &value)
AWS_EC2_API PlacementGroup & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
PlacementGroup & WithGroupId(const Aws::String &value)
PlacementGroup & WithStrategy(PlacementStrategy &&value)
void SetTags(const Aws::Vector< Tag > &value)
void SetState(PlacementGroupState &&value)
AWS_EC2_API void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
const PlacementGroupState & GetState() const
PlacementGroup & WithSpreadLevel(SpreadLevel &&value)
PlacementGroup & WithGroupArn(Aws::String &&value)
const Aws::String & GetGroupArn() const
void SetGroupName(const char *value)
void SetGroupId(const char *value)
PlacementGroup & AddTags(const Tag &value)
PlacementGroup & WithPartitionCount(int value)
void SetState(const PlacementGroupState &value)
void SetSpreadLevel(const SpreadLevel &value)
const Aws::String & GetGroupName() const
void SetStrategy(const PlacementStrategy &value)
PlacementGroup & WithGroupId(const char *value)
PlacementGroup & WithStrategy(const PlacementStrategy &value)
const SpreadLevel & GetSpreadLevel() const
PlacementGroup & WithGroupName(const Aws::String &value)
PlacementGroup & WithGroupName(Aws::String &&value)
PlacementGroup & WithTags(Aws::Vector< Tag > &&value)
PlacementGroup & WithGroupName(const char *value)
const PlacementStrategy & GetStrategy() const
PlacementGroup & WithState(const PlacementGroupState &value)
AWS_EC2_API PlacementGroup(const Aws::Utils::Xml::XmlNode &xmlNode)
PlacementGroup & WithGroupArn(const char *value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
std::basic_ostream< char, std::char_traits< char > > OStream