AWS SDK for C++

AWS SDK for C++ Version 1.11.820

Loading...
Searching...
No Matches
ServiceEvent.h
1
6#pragma once
7#include <aws/core/utils/DateTime.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/resiliencehubv2/Resiliencehubv2_EXPORTS.h>
10#include <aws/resiliencehubv2/model/EventActor.h>
11#include <aws/resiliencehubv2/model/ServiceEventDetails.h>
12#include <aws/resiliencehubv2/model/ServiceEventType.h>
13
14#include <utility>
15
16namespace Aws {
17namespace Utils {
18namespace Json {
19class JsonValue;
20class JsonView;
21} // namespace Json
22} // namespace Utils
23namespace resiliencehubv2 {
24namespace Model {
25
32 public:
33 AWS_RESILIENCEHUBV2_API ServiceEvent() = default;
34 AWS_RESILIENCEHUBV2_API ServiceEvent(Aws::Utils::Json::JsonView jsonValue);
35 AWS_RESILIENCEHUBV2_API ServiceEvent& operator=(Aws::Utils::Json::JsonView jsonValue);
36 AWS_RESILIENCEHUBV2_API Aws::Utils::Json::JsonValue Jsonize() const;
37
39
42 inline const Aws::String& GetEventId() const { return m_eventId; }
43 inline bool EventIdHasBeenSet() const { return m_eventIdHasBeenSet; }
44 template <typename EventIdT = Aws::String>
45 void SetEventId(EventIdT&& value) {
46 m_eventIdHasBeenSet = true;
47 m_eventId = std::forward<EventIdT>(value);
48 }
49 template <typename EventIdT = Aws::String>
50 ServiceEvent& WithEventId(EventIdT&& value) {
51 SetEventId(std::forward<EventIdT>(value));
52 return *this;
53 }
55
57
60 inline const Aws::Utils::DateTime& GetTimestamp() const { return m_timestamp; }
61 inline bool TimestampHasBeenSet() const { return m_timestampHasBeenSet; }
62 template <typename TimestampT = Aws::Utils::DateTime>
63 void SetTimestamp(TimestampT&& value) {
64 m_timestampHasBeenSet = true;
65 m_timestamp = std::forward<TimestampT>(value);
66 }
67 template <typename TimestampT = Aws::Utils::DateTime>
68 ServiceEvent& WithTimestamp(TimestampT&& value) {
69 SetTimestamp(std::forward<TimestampT>(value));
70 return *this;
71 }
73
75
78 inline ServiceEventType GetEventType() const { return m_eventType; }
79 inline bool EventTypeHasBeenSet() const { return m_eventTypeHasBeenSet; }
80 inline void SetEventType(ServiceEventType value) {
81 m_eventTypeHasBeenSet = true;
82 m_eventType = value;
83 }
85 SetEventType(value);
86 return *this;
87 }
89
91
92 inline const Aws::String& GetServiceArn() const { return m_serviceArn; }
93 inline bool ServiceArnHasBeenSet() const { return m_serviceArnHasBeenSet; }
94 template <typename ServiceArnT = Aws::String>
95 void SetServiceArn(ServiceArnT&& value) {
96 m_serviceArnHasBeenSet = true;
97 m_serviceArn = std::forward<ServiceArnT>(value);
98 }
99 template <typename ServiceArnT = Aws::String>
100 ServiceEvent& WithServiceArn(ServiceArnT&& value) {
101 SetServiceArn(std::forward<ServiceArnT>(value));
102 return *this;
103 }
105
107
110 inline const EventActor& GetActor() const { return m_actor; }
111 inline bool ActorHasBeenSet() const { return m_actorHasBeenSet; }
112 template <typename ActorT = EventActor>
113 void SetActor(ActorT&& value) {
114 m_actorHasBeenSet = true;
115 m_actor = std::forward<ActorT>(value);
116 }
117 template <typename ActorT = EventActor>
118 ServiceEvent& WithActor(ActorT&& value) {
119 SetActor(std::forward<ActorT>(value));
120 return *this;
121 }
123
125
128 inline const ServiceEventDetails& GetEventDetails() const { return m_eventDetails; }
129 inline bool EventDetailsHasBeenSet() const { return m_eventDetailsHasBeenSet; }
130 template <typename EventDetailsT = ServiceEventDetails>
131 void SetEventDetails(EventDetailsT&& value) {
132 m_eventDetailsHasBeenSet = true;
133 m_eventDetails = std::forward<EventDetailsT>(value);
134 }
135 template <typename EventDetailsT = ServiceEventDetails>
136 ServiceEvent& WithEventDetails(EventDetailsT&& value) {
137 SetEventDetails(std::forward<EventDetailsT>(value));
138 return *this;
139 }
141 private:
142 Aws::String m_eventId;
143
144 Aws::Utils::DateTime m_timestamp{};
145
147
148 Aws::String m_serviceArn;
149
150 EventActor m_actor;
151
152 ServiceEventDetails m_eventDetails;
153 bool m_eventIdHasBeenSet = false;
154 bool m_timestampHasBeenSet = false;
155 bool m_eventTypeHasBeenSet = false;
156 bool m_serviceArnHasBeenSet = false;
157 bool m_actorHasBeenSet = false;
158 bool m_eventDetailsHasBeenSet = false;
159};
160
161} // namespace Model
162} // namespace resiliencehubv2
163} // namespace Aws
const EventActor & GetActor() const
ServiceEvent & WithEventType(ServiceEventType value)
AWS_RESILIENCEHUBV2_API Aws::Utils::Json::JsonValue Jsonize() const
void SetTimestamp(TimestampT &&value)
const Aws::Utils::DateTime & GetTimestamp() const
AWS_RESILIENCEHUBV2_API ServiceEvent & operator=(Aws::Utils::Json::JsonView jsonValue)
AWS_RESILIENCEHUBV2_API ServiceEvent()=default
const ServiceEventDetails & GetEventDetails() const
void SetEventDetails(EventDetailsT &&value)
ServiceEvent & WithTimestamp(TimestampT &&value)
ServiceEvent & WithEventDetails(EventDetailsT &&value)
const Aws::String & GetServiceArn() const
void SetServiceArn(ServiceArnT &&value)
ServiceEvent & WithEventId(EventIdT &&value)
ServiceEventType GetEventType() const
AWS_RESILIENCEHUBV2_API ServiceEvent(Aws::Utils::Json::JsonView jsonValue)
void SetEventType(ServiceEventType value)
const Aws::String & GetEventId() const
ServiceEvent & WithActor(ActorT &&value)
ServiceEvent & WithServiceArn(ServiceArnT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue