AWS SDK for C++

AWS SDK for C++ Version 1.11.716

Loading...
Searching...
No Matches
Event.h
1
6#pragma once
7#include <aws/core/utils/DateTime.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/rds/RDS_EXPORTS.h>
12#include <aws/rds/model/SourceType.h>
13
14#include <utility>
15
16namespace Aws {
17namespace Utils {
18namespace Xml {
19class XmlNode;
20} // namespace Xml
21} // namespace Utils
22namespace RDS {
23namespace Model {
24
32class Event {
33 public:
34 AWS_RDS_API Event() = default;
35 AWS_RDS_API Event(const Aws::Utils::Xml::XmlNode& xmlNode);
36 AWS_RDS_API Event& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
37
38 AWS_RDS_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
39 AWS_RDS_API void OutputToStream(Aws::OStream& oStream, const char* location) const;
40
42
45 inline const Aws::String& GetSourceIdentifier() const { return m_sourceIdentifier; }
46 inline bool SourceIdentifierHasBeenSet() const { return m_sourceIdentifierHasBeenSet; }
47 template <typename SourceIdentifierT = Aws::String>
48 void SetSourceIdentifier(SourceIdentifierT&& value) {
49 m_sourceIdentifierHasBeenSet = true;
50 m_sourceIdentifier = std::forward<SourceIdentifierT>(value);
51 }
52 template <typename SourceIdentifierT = Aws::String>
53 Event& WithSourceIdentifier(SourceIdentifierT&& value) {
54 SetSourceIdentifier(std::forward<SourceIdentifierT>(value));
55 return *this;
56 }
58
60
63 inline SourceType GetSourceType() const { return m_sourceType; }
64 inline bool SourceTypeHasBeenSet() const { return m_sourceTypeHasBeenSet; }
65 inline void SetSourceType(SourceType value) {
66 m_sourceTypeHasBeenSet = true;
67 m_sourceType = value;
68 }
70 SetSourceType(value);
71 return *this;
72 }
74
76
79 inline const Aws::String& GetMessage() const { return m_message; }
80 inline bool MessageHasBeenSet() const { return m_messageHasBeenSet; }
81 template <typename MessageT = Aws::String>
82 void SetMessage(MessageT&& value) {
83 m_messageHasBeenSet = true;
84 m_message = std::forward<MessageT>(value);
85 }
86 template <typename MessageT = Aws::String>
87 Event& WithMessage(MessageT&& value) {
88 SetMessage(std::forward<MessageT>(value));
89 return *this;
90 }
92
94
97 inline const Aws::Vector<Aws::String>& GetEventCategories() const { return m_eventCategories; }
98 inline bool EventCategoriesHasBeenSet() const { return m_eventCategoriesHasBeenSet; }
99 template <typename EventCategoriesT = Aws::Vector<Aws::String>>
100 void SetEventCategories(EventCategoriesT&& value) {
101 m_eventCategoriesHasBeenSet = true;
102 m_eventCategories = std::forward<EventCategoriesT>(value);
103 }
104 template <typename EventCategoriesT = Aws::Vector<Aws::String>>
105 Event& WithEventCategories(EventCategoriesT&& value) {
106 SetEventCategories(std::forward<EventCategoriesT>(value));
107 return *this;
108 }
109 template <typename EventCategoriesT = Aws::String>
110 Event& AddEventCategories(EventCategoriesT&& value) {
111 m_eventCategoriesHasBeenSet = true;
112 m_eventCategories.emplace_back(std::forward<EventCategoriesT>(value));
113 return *this;
114 }
116
118
121 inline const Aws::Utils::DateTime& GetDate() const { return m_date; }
122 inline bool DateHasBeenSet() const { return m_dateHasBeenSet; }
123 template <typename DateT = Aws::Utils::DateTime>
124 void SetDate(DateT&& value) {
125 m_dateHasBeenSet = true;
126 m_date = std::forward<DateT>(value);
127 }
128 template <typename DateT = Aws::Utils::DateTime>
129 Event& WithDate(DateT&& value) {
130 SetDate(std::forward<DateT>(value));
131 return *this;
132 }
134
136
139 inline const Aws::String& GetSourceArn() const { return m_sourceArn; }
140 inline bool SourceArnHasBeenSet() const { return m_sourceArnHasBeenSet; }
141 template <typename SourceArnT = Aws::String>
142 void SetSourceArn(SourceArnT&& value) {
143 m_sourceArnHasBeenSet = true;
144 m_sourceArn = std::forward<SourceArnT>(value);
145 }
146 template <typename SourceArnT = Aws::String>
147 Event& WithSourceArn(SourceArnT&& value) {
148 SetSourceArn(std::forward<SourceArnT>(value));
149 return *this;
150 }
152 private:
153 Aws::String m_sourceIdentifier;
154
155 SourceType m_sourceType{SourceType::NOT_SET};
156
157 Aws::String m_message;
158
159 Aws::Vector<Aws::String> m_eventCategories;
160
161 Aws::Utils::DateTime m_date{};
162
163 Aws::String m_sourceArn;
164 bool m_sourceIdentifierHasBeenSet = false;
165 bool m_sourceTypeHasBeenSet = false;
166 bool m_messageHasBeenSet = false;
167 bool m_eventCategoriesHasBeenSet = false;
168 bool m_dateHasBeenSet = false;
169 bool m_sourceArnHasBeenSet = false;
170};
171
172} // namespace Model
173} // namespace RDS
174} // namespace Aws
Event & WithEventCategories(EventCategoriesT &&value)
Definition Event.h:105
AWS_RDS_API Event(const Aws::Utils::Xml::XmlNode &xmlNode)
const Aws::Utils::DateTime & GetDate() const
Definition Event.h:121
const Aws::String & GetSourceArn() const
Definition Event.h:139
Event & WithSourceType(SourceType value)
Definition Event.h:69
AWS_RDS_API void OutputToStream(Aws::OStream &oStream, const char *location) const
Event & WithSourceIdentifier(SourceIdentifierT &&value)
Definition Event.h:53
bool DateHasBeenSet() const
Definition Event.h:122
SourceType GetSourceType() const
Definition Event.h:63
const Aws::Vector< Aws::String > & GetEventCategories() const
Definition Event.h:97
Event & AddEventCategories(EventCategoriesT &&value)
Definition Event.h:110
bool SourceIdentifierHasBeenSet() const
Definition Event.h:46
bool SourceArnHasBeenSet() const
Definition Event.h:140
Event & WithSourceArn(SourceArnT &&value)
Definition Event.h:147
void SetSourceIdentifier(SourceIdentifierT &&value)
Definition Event.h:48
const Aws::String & GetSourceIdentifier() const
Definition Event.h:45
bool EventCategoriesHasBeenSet() const
Definition Event.h:98
const Aws::String & GetMessage() const
Definition Event.h:79
bool SourceTypeHasBeenSet() const
Definition Event.h:64
Event & WithDate(DateT &&value)
Definition Event.h:129
AWS_RDS_API Event & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
void SetMessage(MessageT &&value)
Definition Event.h:82
Event & WithMessage(MessageT &&value)
Definition Event.h:87
void SetSourceType(SourceType value)
Definition Event.h:65
void SetEventCategories(EventCategoriesT &&value)
Definition Event.h:100
void SetSourceArn(SourceArnT &&value)
Definition Event.h:142
void SetDate(DateT &&value)
Definition Event.h:124
bool MessageHasBeenSet() const
Definition Event.h:80
AWS_RDS_API void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
AWS_RDS_API Event()=default
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