AWS SDK for C++

AWS SDK for C++ Version 1.11.743

Loading...
Searching...
No Matches
ValidationException.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/evs/EVS_EXPORTS.h>
10#include <aws/evs/model/ValidationExceptionField.h>
11#include <aws/evs/model/ValidationExceptionReason.h>
12
13#include <utility>
14
15namespace Aws {
16namespace Utils {
17namespace Json {
18class JsonValue;
19class JsonView;
20} // namespace Json
21} // namespace Utils
22namespace EVS {
23namespace Model {
24
34 public:
35 AWS_EVS_API ValidationException() = default;
39
41
44 inline const Aws::String& GetMessage() const { return m_message; }
45 inline bool MessageHasBeenSet() const { return m_messageHasBeenSet; }
46 template <typename MessageT = Aws::String>
47 void SetMessage(MessageT&& value) {
48 m_messageHasBeenSet = true;
49 m_message = std::forward<MessageT>(value);
50 }
51 template <typename MessageT = Aws::String>
52 ValidationException& WithMessage(MessageT&& value) {
53 SetMessage(std::forward<MessageT>(value));
54 return *this;
55 }
57
59
62 inline ValidationExceptionReason GetReason() const { return m_reason; }
63 inline bool ReasonHasBeenSet() const { return m_reasonHasBeenSet; }
65 m_reasonHasBeenSet = true;
66 m_reason = value;
67 }
69 SetReason(value);
70 return *this;
71 }
73
75
78 inline const Aws::Vector<ValidationExceptionField>& GetFieldList() const { return m_fieldList; }
79 inline bool FieldListHasBeenSet() const { return m_fieldListHasBeenSet; }
80 template <typename FieldListT = Aws::Vector<ValidationExceptionField>>
81 void SetFieldList(FieldListT&& value) {
82 m_fieldListHasBeenSet = true;
83 m_fieldList = std::forward<FieldListT>(value);
84 }
85 template <typename FieldListT = Aws::Vector<ValidationExceptionField>>
86 ValidationException& WithFieldList(FieldListT&& value) {
87 SetFieldList(std::forward<FieldListT>(value));
88 return *this;
89 }
90 template <typename FieldListT = ValidationExceptionField>
91 ValidationException& AddFieldList(FieldListT&& value) {
92 m_fieldListHasBeenSet = true;
93 m_fieldList.emplace_back(std::forward<FieldListT>(value));
94 return *this;
95 }
97 private:
98 Aws::String m_message;
99
101
103 bool m_messageHasBeenSet = false;
104 bool m_reasonHasBeenSet = false;
105 bool m_fieldListHasBeenSet = false;
106};
107
108} // namespace Model
109} // namespace EVS
110} // namespace Aws
const Aws::Vector< ValidationExceptionField > & GetFieldList() const
ValidationException & WithReason(ValidationExceptionReason value)
AWS_EVS_API ValidationException(Aws::Utils::Json::JsonView jsonValue)
ValidationException & AddFieldList(FieldListT &&value)
ValidationException & WithMessage(MessageT &&value)
AWS_EVS_API ValidationException()=default
void SetReason(ValidationExceptionReason value)
AWS_EVS_API Aws::Utils::Json::JsonValue Jsonize() const
AWS_EVS_API ValidationException & operator=(Aws::Utils::Json::JsonView jsonValue)
ValidationException & WithFieldList(FieldListT &&value)
ValidationExceptionReason GetReason() const
const Aws::String & GetMessage() 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