AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
UsageLimit.h
1
6#pragma once
7#include <aws/redshift/Redshift_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSStreamFwd.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/redshift/model/UsageLimitFeatureType.h>
11#include <aws/redshift/model/UsageLimitLimitType.h>
12#include <aws/redshift/model/UsageLimitPeriod.h>
13#include <aws/redshift/model/UsageLimitBreachAction.h>
14#include <aws/core/utils/memory/stl/AWSVector.h>
15#include <aws/redshift/model/ResponseMetadata.h>
16#include <aws/redshift/model/Tag.h>
17#include <utility>
18
19namespace Aws
20{
21namespace Utils
22{
23namespace Xml
24{
25 class XmlNode;
26} // namespace Xml
27} // namespace Utils
28namespace Redshift
29{
30namespace Model
31{
32
39 {
40 public:
41 AWS_REDSHIFT_API UsageLimit() = default;
42 AWS_REDSHIFT_API UsageLimit(const Aws::Utils::Xml::XmlNode& xmlNode);
43 AWS_REDSHIFT_API UsageLimit& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
44
45 AWS_REDSHIFT_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
46 AWS_REDSHIFT_API void OutputToStream(Aws::OStream& oStream, const char* location) const;
47
48
50
53 inline const Aws::String& GetUsageLimitId() const { return m_usageLimitId; }
54 inline bool UsageLimitIdHasBeenSet() const { return m_usageLimitIdHasBeenSet; }
55 template<typename UsageLimitIdT = Aws::String>
56 void SetUsageLimitId(UsageLimitIdT&& value) { m_usageLimitIdHasBeenSet = true; m_usageLimitId = std::forward<UsageLimitIdT>(value); }
57 template<typename UsageLimitIdT = Aws::String>
58 UsageLimit& WithUsageLimitId(UsageLimitIdT&& value) { SetUsageLimitId(std::forward<UsageLimitIdT>(value)); return *this;}
60
62
65 inline const Aws::String& GetClusterIdentifier() const { return m_clusterIdentifier; }
66 inline bool ClusterIdentifierHasBeenSet() const { return m_clusterIdentifierHasBeenSet; }
67 template<typename ClusterIdentifierT = Aws::String>
68 void SetClusterIdentifier(ClusterIdentifierT&& value) { m_clusterIdentifierHasBeenSet = true; m_clusterIdentifier = std::forward<ClusterIdentifierT>(value); }
69 template<typename ClusterIdentifierT = Aws::String>
70 UsageLimit& WithClusterIdentifier(ClusterIdentifierT&& value) { SetClusterIdentifier(std::forward<ClusterIdentifierT>(value)); return *this;}
72
74
77 inline UsageLimitFeatureType GetFeatureType() const { return m_featureType; }
78 inline bool FeatureTypeHasBeenSet() const { return m_featureTypeHasBeenSet; }
79 inline void SetFeatureType(UsageLimitFeatureType value) { m_featureTypeHasBeenSet = true; m_featureType = value; }
80 inline UsageLimit& WithFeatureType(UsageLimitFeatureType value) { SetFeatureType(value); return *this;}
82
84
88 inline UsageLimitLimitType GetLimitType() const { return m_limitType; }
89 inline bool LimitTypeHasBeenSet() const { return m_limitTypeHasBeenSet; }
90 inline void SetLimitType(UsageLimitLimitType value) { m_limitTypeHasBeenSet = true; m_limitType = value; }
91 inline UsageLimit& WithLimitType(UsageLimitLimitType value) { SetLimitType(value); return *this;}
93
95
99 inline long long GetAmount() const { return m_amount; }
100 inline bool AmountHasBeenSet() const { return m_amountHasBeenSet; }
101 inline void SetAmount(long long value) { m_amountHasBeenSet = true; m_amount = value; }
102 inline UsageLimit& WithAmount(long long value) { SetAmount(value); return *this;}
104
106
110 inline UsageLimitPeriod GetPeriod() const { return m_period; }
111 inline bool PeriodHasBeenSet() const { return m_periodHasBeenSet; }
112 inline void SetPeriod(UsageLimitPeriod value) { m_periodHasBeenSet = true; m_period = value; }
113 inline UsageLimit& WithPeriod(UsageLimitPeriod value) { SetPeriod(value); return *this;}
115
117
124 inline UsageLimitBreachAction GetBreachAction() const { return m_breachAction; }
125 inline bool BreachActionHasBeenSet() const { return m_breachActionHasBeenSet; }
126 inline void SetBreachAction(UsageLimitBreachAction value) { m_breachActionHasBeenSet = true; m_breachAction = value; }
129
131
134 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
135 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
136 template<typename TagsT = Aws::Vector<Tag>>
137 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
138 template<typename TagsT = Aws::Vector<Tag>>
139 UsageLimit& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
140 template<typename TagsT = Tag>
141 UsageLimit& AddTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags.emplace_back(std::forward<TagsT>(value)); return *this; }
143
145
146 inline const ResponseMetadata& GetResponseMetadata() const { return m_responseMetadata; }
147 template<typename ResponseMetadataT = ResponseMetadata>
148 void SetResponseMetadata(ResponseMetadataT&& value) { m_responseMetadataHasBeenSet = true; m_responseMetadata = std::forward<ResponseMetadataT>(value); }
149 template<typename ResponseMetadataT = ResponseMetadata>
150 UsageLimit& WithResponseMetadata(ResponseMetadataT&& value) { SetResponseMetadata(std::forward<ResponseMetadataT>(value)); return *this;}
152 private:
153
154 Aws::String m_usageLimitId;
155 bool m_usageLimitIdHasBeenSet = false;
156
157 Aws::String m_clusterIdentifier;
158 bool m_clusterIdentifierHasBeenSet = false;
159
161 bool m_featureTypeHasBeenSet = false;
162
164 bool m_limitTypeHasBeenSet = false;
165
166 long long m_amount{0};
167 bool m_amountHasBeenSet = false;
168
170 bool m_periodHasBeenSet = false;
171
173 bool m_breachActionHasBeenSet = false;
174
175 Aws::Vector<Tag> m_tags;
176 bool m_tagsHasBeenSet = false;
177
178 ResponseMetadata m_responseMetadata;
179 bool m_responseMetadataHasBeenSet = true;
180 };
181
182} // namespace Model
183} // namespace Redshift
184} // namespace Aws
void SetAmount(long long value)
Definition UsageLimit.h:101
void SetUsageLimitId(UsageLimitIdT &&value)
Definition UsageLimit.h:56
UsageLimitFeatureType GetFeatureType() const
Definition UsageLimit.h:77
void SetLimitType(UsageLimitLimitType value)
Definition UsageLimit.h:90
UsageLimit & WithUsageLimitId(UsageLimitIdT &&value)
Definition UsageLimit.h:58
UsageLimit & WithResponseMetadata(ResponseMetadataT &&value)
Definition UsageLimit.h:150
const Aws::String & GetClusterIdentifier() const
Definition UsageLimit.h:65
UsageLimit & WithFeatureType(UsageLimitFeatureType value)
Definition UsageLimit.h:80
UsageLimit & WithPeriod(UsageLimitPeriod value)
Definition UsageLimit.h:113
void SetResponseMetadata(ResponseMetadataT &&value)
Definition UsageLimit.h:148
UsageLimitBreachAction GetBreachAction() const
Definition UsageLimit.h:124
UsageLimit & WithLimitType(UsageLimitLimitType value)
Definition UsageLimit.h:91
AWS_REDSHIFT_API void OutputToStream(Aws::OStream &oStream, const char *location) const
AWS_REDSHIFT_API UsageLimit & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
void SetTags(TagsT &&value)
Definition UsageLimit.h:137
UsageLimitPeriod GetPeriod() const
Definition UsageLimit.h:110
AWS_REDSHIFT_API void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
const Aws::String & GetUsageLimitId() const
Definition UsageLimit.h:53
const Aws::Vector< Tag > & GetTags() const
Definition UsageLimit.h:134
void SetClusterIdentifier(ClusterIdentifierT &&value)
Definition UsageLimit.h:68
UsageLimit & WithAmount(long long value)
Definition UsageLimit.h:102
UsageLimit & AddTags(TagsT &&value)
Definition UsageLimit.h:141
UsageLimitLimitType GetLimitType() const
Definition UsageLimit.h:88
bool ClusterIdentifierHasBeenSet() const
Definition UsageLimit.h:66
AWS_REDSHIFT_API UsageLimit(const Aws::Utils::Xml::XmlNode &xmlNode)
void SetFeatureType(UsageLimitFeatureType value)
Definition UsageLimit.h:79
void SetBreachAction(UsageLimitBreachAction value)
Definition UsageLimit.h:126
void SetPeriod(UsageLimitPeriod value)
Definition UsageLimit.h:112
AWS_REDSHIFT_API UsageLimit()=default
UsageLimit & WithBreachAction(UsageLimitBreachAction value)
Definition UsageLimit.h:127
const ResponseMetadata & GetResponseMetadata() const
Definition UsageLimit.h:146
UsageLimit & WithTags(TagsT &&value)
Definition UsageLimit.h:139
UsageLimit & WithClusterIdentifier(ClusterIdentifierT &&value)
Definition UsageLimit.h:70
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