AWS SDK for C++

AWS SDK for C++ Version 1.11.717

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/m2/MainframeModernization_EXPORTS.h>
10#include <aws/m2/model/ValidationExceptionField.h>
11#include <aws/m2/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 MainframeModernization {
23namespace Model {
24
32 public:
33 AWS_MAINFRAMEMODERNIZATION_API ValidationException() = default;
34 AWS_MAINFRAMEMODERNIZATION_API ValidationException(Aws::Utils::Json::JsonView jsonValue);
35 AWS_MAINFRAMEMODERNIZATION_API ValidationException& operator=(Aws::Utils::Json::JsonView jsonValue);
36 AWS_MAINFRAMEMODERNIZATION_API Aws::Utils::Json::JsonValue Jsonize() const;
37
39
42 inline const Aws::Vector<ValidationExceptionField>& GetFieldList() const { return m_fieldList; }
43 inline bool FieldListHasBeenSet() const { return m_fieldListHasBeenSet; }
44 template <typename FieldListT = Aws::Vector<ValidationExceptionField>>
45 void SetFieldList(FieldListT&& value) {
46 m_fieldListHasBeenSet = true;
47 m_fieldList = std::forward<FieldListT>(value);
48 }
49 template <typename FieldListT = Aws::Vector<ValidationExceptionField>>
50 ValidationException& WithFieldList(FieldListT&& value) {
51 SetFieldList(std::forward<FieldListT>(value));
52 return *this;
53 }
54 template <typename FieldListT = ValidationExceptionField>
55 ValidationException& AddFieldList(FieldListT&& value) {
56 m_fieldListHasBeenSet = true;
57 m_fieldList.emplace_back(std::forward<FieldListT>(value));
58 return *this;
59 }
61
63
64 inline const Aws::String& GetMessage() const { return m_message; }
65 inline bool MessageHasBeenSet() const { return m_messageHasBeenSet; }
66 template <typename MessageT = Aws::String>
67 void SetMessage(MessageT&& value) {
68 m_messageHasBeenSet = true;
69 m_message = std::forward<MessageT>(value);
70 }
71 template <typename MessageT = Aws::String>
72 ValidationException& WithMessage(MessageT&& value) {
73 SetMessage(std::forward<MessageT>(value));
74 return *this;
75 }
77
79
82 inline ValidationExceptionReason GetReason() const { return m_reason; }
83 inline bool ReasonHasBeenSet() const { return m_reasonHasBeenSet; }
85 m_reasonHasBeenSet = true;
86 m_reason = value;
87 }
89 SetReason(value);
90 return *this;
91 }
93 private:
95
96 Aws::String m_message;
97
99 bool m_fieldListHasBeenSet = false;
100 bool m_messageHasBeenSet = false;
101 bool m_reasonHasBeenSet = false;
102};
103
104} // namespace Model
105} // namespace MainframeModernization
106} // namespace Aws
ValidationException & WithMessage(MessageT &&value)
AWS_MAINFRAMEMODERNIZATION_API Aws::Utils::Json::JsonValue Jsonize() const
const Aws::Vector< ValidationExceptionField > & GetFieldList() const
AWS_MAINFRAMEMODERNIZATION_API ValidationException()=default
AWS_MAINFRAMEMODERNIZATION_API ValidationException(Aws::Utils::Json::JsonView jsonValue)
ValidationException & AddFieldList(FieldListT &&value)
ValidationException & WithFieldList(FieldListT &&value)
ValidationException & WithReason(ValidationExceptionReason value)
AWS_MAINFRAMEMODERNIZATION_API ValidationException & operator=(Aws::Utils::Json::JsonView jsonValue)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue