AWS SDK for C++

AWS SDK for C++ Version 1.11.717

Loading...
Searching...
No Matches
ConflictException.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSString.h>
8#include <aws/core/utils/memory/stl/AWSVector.h>
9#include <aws/mgn/Mgn_EXPORTS.h>
10#include <aws/mgn/model/ErrorDetails.h>
11
12#include <utility>
13
14namespace Aws {
15namespace Utils {
16namespace Json {
17class JsonValue;
18class JsonView;
19} // namespace Json
20} // namespace Utils
21namespace mgn {
22namespace Model {
23
31 public:
32 AWS_MGN_API ConflictException() = default;
36
38
39 inline const Aws::String& GetMessage() const { return m_message; }
40 inline bool MessageHasBeenSet() const { return m_messageHasBeenSet; }
41 template <typename MessageT = Aws::String>
42 void SetMessage(MessageT&& value) {
43 m_messageHasBeenSet = true;
44 m_message = std::forward<MessageT>(value);
45 }
46 template <typename MessageT = Aws::String>
47 ConflictException& WithMessage(MessageT&& value) {
48 SetMessage(std::forward<MessageT>(value));
49 return *this;
50 }
52
54
55 inline const Aws::String& GetCode() const { return m_code; }
56 inline bool CodeHasBeenSet() const { return m_codeHasBeenSet; }
57 template <typename CodeT = Aws::String>
58 void SetCode(CodeT&& value) {
59 m_codeHasBeenSet = true;
60 m_code = std::forward<CodeT>(value);
61 }
62 template <typename CodeT = Aws::String>
63 ConflictException& WithCode(CodeT&& value) {
64 SetCode(std::forward<CodeT>(value));
65 return *this;
66 }
68
70
73 inline const Aws::String& GetResourceId() const { return m_resourceId; }
74 inline bool ResourceIdHasBeenSet() const { return m_resourceIdHasBeenSet; }
75 template <typename ResourceIdT = Aws::String>
76 void SetResourceId(ResourceIdT&& value) {
77 m_resourceIdHasBeenSet = true;
78 m_resourceId = std::forward<ResourceIdT>(value);
79 }
80 template <typename ResourceIdT = Aws::String>
81 ConflictException& WithResourceId(ResourceIdT&& value) {
82 SetResourceId(std::forward<ResourceIdT>(value));
83 return *this;
84 }
86
88
91 inline const Aws::String& GetResourceType() const { return m_resourceType; }
92 inline bool ResourceTypeHasBeenSet() const { return m_resourceTypeHasBeenSet; }
93 template <typename ResourceTypeT = Aws::String>
94 void SetResourceType(ResourceTypeT&& value) {
95 m_resourceTypeHasBeenSet = true;
96 m_resourceType = std::forward<ResourceTypeT>(value);
97 }
98 template <typename ResourceTypeT = Aws::String>
99 ConflictException& WithResourceType(ResourceTypeT&& value) {
100 SetResourceType(std::forward<ResourceTypeT>(value));
101 return *this;
102 }
104
106
109 inline const Aws::Vector<ErrorDetails>& GetErrors() const { return m_errors; }
110 inline bool ErrorsHasBeenSet() const { return m_errorsHasBeenSet; }
111 template <typename ErrorsT = Aws::Vector<ErrorDetails>>
112 void SetErrors(ErrorsT&& value) {
113 m_errorsHasBeenSet = true;
114 m_errors = std::forward<ErrorsT>(value);
115 }
116 template <typename ErrorsT = Aws::Vector<ErrorDetails>>
117 ConflictException& WithErrors(ErrorsT&& value) {
118 SetErrors(std::forward<ErrorsT>(value));
119 return *this;
120 }
121 template <typename ErrorsT = ErrorDetails>
122 ConflictException& AddErrors(ErrorsT&& value) {
123 m_errorsHasBeenSet = true;
124 m_errors.emplace_back(std::forward<ErrorsT>(value));
125 return *this;
126 }
128 private:
129 Aws::String m_message;
130
131 Aws::String m_code;
132
133 Aws::String m_resourceId;
134
135 Aws::String m_resourceType;
136
138 bool m_messageHasBeenSet = false;
139 bool m_codeHasBeenSet = false;
140 bool m_resourceIdHasBeenSet = false;
141 bool m_resourceTypeHasBeenSet = false;
142 bool m_errorsHasBeenSet = false;
143};
144
145} // namespace Model
146} // namespace mgn
147} // namespace Aws
ConflictException & WithErrors(ErrorsT &&value)
const Aws::Vector< ErrorDetails > & GetErrors() const
const Aws::String & GetMessage() const
AWS_MGN_API Aws::Utils::Json::JsonValue Jsonize() const
void SetResourceId(ResourceIdT &&value)
AWS_MGN_API ConflictException()=default
void SetResourceType(ResourceTypeT &&value)
AWS_MGN_API ConflictException(Aws::Utils::Json::JsonView jsonValue)
ConflictException & AddErrors(ErrorsT &&value)
ConflictException & WithResourceType(ResourceTypeT &&value)
ConflictException & WithCode(CodeT &&value)
ConflictException & WithResourceId(ResourceIdT &&value)
ConflictException & WithMessage(MessageT &&value)
const Aws::String & GetResourceType() const
AWS_MGN_API ConflictException & operator=(Aws::Utils::Json::JsonView jsonValue)
const Aws::String & GetCode() const
const Aws::String & GetResourceId() const
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue