AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
InstanceEventWindow.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/core/utils/memory/stl/AWSVector.h>
11#include <aws/ec2/model/InstanceEventWindowAssociationTarget.h>
12#include <aws/ec2/model/InstanceEventWindowState.h>
13#include <aws/ec2/model/InstanceEventWindowTimeRange.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 InstanceEventWindow() = default;
40 AWS_EC2_API InstanceEventWindow(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& GetInstanceEventWindowId() const { return m_instanceEventWindowId; }
52 inline bool InstanceEventWindowIdHasBeenSet() const { return m_instanceEventWindowIdHasBeenSet; }
53 template<typename InstanceEventWindowIdT = Aws::String>
54 void SetInstanceEventWindowId(InstanceEventWindowIdT&& value) { m_instanceEventWindowIdHasBeenSet = true; m_instanceEventWindowId = std::forward<InstanceEventWindowIdT>(value); }
55 template<typename InstanceEventWindowIdT = Aws::String>
56 InstanceEventWindow& WithInstanceEventWindowId(InstanceEventWindowIdT&& value) { SetInstanceEventWindowId(std::forward<InstanceEventWindowIdT>(value)); return *this;}
58
60
63 inline const Aws::Vector<InstanceEventWindowTimeRange>& GetTimeRanges() const { return m_timeRanges; }
64 inline bool TimeRangesHasBeenSet() const { return m_timeRangesHasBeenSet; }
65 template<typename TimeRangesT = Aws::Vector<InstanceEventWindowTimeRange>>
66 void SetTimeRanges(TimeRangesT&& value) { m_timeRangesHasBeenSet = true; m_timeRanges = std::forward<TimeRangesT>(value); }
67 template<typename TimeRangesT = Aws::Vector<InstanceEventWindowTimeRange>>
68 InstanceEventWindow& WithTimeRanges(TimeRangesT&& value) { SetTimeRanges(std::forward<TimeRangesT>(value)); return *this;}
69 template<typename TimeRangesT = InstanceEventWindowTimeRange>
70 InstanceEventWindow& AddTimeRanges(TimeRangesT&& value) { m_timeRangesHasBeenSet = true; m_timeRanges.emplace_back(std::forward<TimeRangesT>(value)); return *this; }
72
74
77 inline const Aws::String& GetName() const { return m_name; }
78 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
79 template<typename NameT = Aws::String>
80 void SetName(NameT&& value) { m_nameHasBeenSet = true; m_name = std::forward<NameT>(value); }
81 template<typename NameT = Aws::String>
82 InstanceEventWindow& WithName(NameT&& value) { SetName(std::forward<NameT>(value)); return *this;}
84
86
89 inline const Aws::String& GetCronExpression() const { return m_cronExpression; }
90 inline bool CronExpressionHasBeenSet() const { return m_cronExpressionHasBeenSet; }
91 template<typename CronExpressionT = Aws::String>
92 void SetCronExpression(CronExpressionT&& value) { m_cronExpressionHasBeenSet = true; m_cronExpression = std::forward<CronExpressionT>(value); }
93 template<typename CronExpressionT = Aws::String>
94 InstanceEventWindow& WithCronExpression(CronExpressionT&& value) { SetCronExpression(std::forward<CronExpressionT>(value)); return *this;}
96
98
101 inline const InstanceEventWindowAssociationTarget& GetAssociationTarget() const { return m_associationTarget; }
102 inline bool AssociationTargetHasBeenSet() const { return m_associationTargetHasBeenSet; }
103 template<typename AssociationTargetT = InstanceEventWindowAssociationTarget>
104 void SetAssociationTarget(AssociationTargetT&& value) { m_associationTargetHasBeenSet = true; m_associationTarget = std::forward<AssociationTargetT>(value); }
105 template<typename AssociationTargetT = InstanceEventWindowAssociationTarget>
106 InstanceEventWindow& WithAssociationTarget(AssociationTargetT&& value) { SetAssociationTarget(std::forward<AssociationTargetT>(value)); return *this;}
108
110
113 inline InstanceEventWindowState GetState() const { return m_state; }
114 inline bool StateHasBeenSet() const { return m_stateHasBeenSet; }
115 inline void SetState(InstanceEventWindowState value) { m_stateHasBeenSet = true; m_state = value; }
116 inline InstanceEventWindow& WithState(InstanceEventWindowState value) { SetState(value); return *this;}
118
120
123 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
124 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
125 template<typename TagsT = Aws::Vector<Tag>>
126 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
127 template<typename TagsT = Aws::Vector<Tag>>
128 InstanceEventWindow& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
129 template<typename TagsT = Tag>
130 InstanceEventWindow& AddTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags.emplace_back(std::forward<TagsT>(value)); return *this; }
132 private:
133
134 Aws::String m_instanceEventWindowId;
135 bool m_instanceEventWindowIdHasBeenSet = false;
136
138 bool m_timeRangesHasBeenSet = false;
139
140 Aws::String m_name;
141 bool m_nameHasBeenSet = false;
142
143 Aws::String m_cronExpression;
144 bool m_cronExpressionHasBeenSet = false;
145
146 InstanceEventWindowAssociationTarget m_associationTarget;
147 bool m_associationTargetHasBeenSet = false;
148
150 bool m_stateHasBeenSet = false;
151
152 Aws::Vector<Tag> m_tags;
153 bool m_tagsHasBeenSet = false;
154 };
155
156} // namespace Model
157} // namespace EC2
158} // namespace Aws
InstanceEventWindow & WithCronExpression(CronExpressionT &&value)
InstanceEventWindow & AddTags(TagsT &&value)
void SetTimeRanges(TimeRangesT &&value)
const Aws::Vector< InstanceEventWindowTimeRange > & GetTimeRanges() const
InstanceEventWindow & WithTimeRanges(TimeRangesT &&value)
const Aws::String & GetCronExpression() const
InstanceEventWindow & WithInstanceEventWindowId(InstanceEventWindowIdT &&value)
AWS_EC2_API InstanceEventWindow()=default
const Aws::String & GetInstanceEventWindowId() const
InstanceEventWindow & WithTags(TagsT &&value)
InstanceEventWindow & WithAssociationTarget(AssociationTargetT &&value)
InstanceEventWindow & AddTimeRanges(TimeRangesT &&value)
const Aws::String & GetName() const
void SetState(InstanceEventWindowState value)
AWS_EC2_API InstanceEventWindow(const Aws::Utils::Xml::XmlNode &xmlNode)
void SetInstanceEventWindowId(InstanceEventWindowIdT &&value)
void SetCronExpression(CronExpressionT &&value)
AWS_EC2_API void OutputToStream(Aws::OStream &oStream, const char *location) const
InstanceEventWindow & WithName(NameT &&value)
AWS_EC2_API void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
InstanceEventWindowState GetState() const
void SetAssociationTarget(AssociationTargetT &&value)
const InstanceEventWindowAssociationTarget & GetAssociationTarget() const
InstanceEventWindow & WithState(InstanceEventWindowState value)
const Aws::Vector< Tag > & GetTags() const
AWS_EC2_API InstanceEventWindow & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
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