AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
ValidationException.h
1
6#pragma once
7#include <aws/invoicing/Invoicing_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/invoicing/model/ValidationExceptionReason.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/invoicing/model/ValidationExceptionField.h>
12#include <utility>
13
14namespace Aws
15{
16namespace Utils
17{
18namespace Json
19{
20 class JsonValue;
21 class JsonView;
22} // namespace Json
23} // namespace Utils
24namespace Invoicing
25{
26namespace Model
27{
28
36 {
37 public:
38 AWS_INVOICING_API ValidationException() = default;
39 AWS_INVOICING_API ValidationException(Aws::Utils::Json::JsonView jsonValue);
41 AWS_INVOICING_API Aws::Utils::Json::JsonValue Jsonize() const;
42
43
45
46 inline const Aws::String& GetMessage() const { return m_message; }
47 inline bool MessageHasBeenSet() const { return m_messageHasBeenSet; }
48 template<typename MessageT = Aws::String>
49 void SetMessage(MessageT&& value) { m_messageHasBeenSet = true; m_message = std::forward<MessageT>(value); }
50 template<typename MessageT = Aws::String>
51 ValidationException& WithMessage(MessageT&& value) { SetMessage(std::forward<MessageT>(value)); return *this;}
53
55
58 inline const Aws::String& GetResourceName() const { return m_resourceName; }
59 inline bool ResourceNameHasBeenSet() const { return m_resourceNameHasBeenSet; }
60 template<typename ResourceNameT = Aws::String>
61 void SetResourceName(ResourceNameT&& value) { m_resourceNameHasBeenSet = true; m_resourceName = std::forward<ResourceNameT>(value); }
62 template<typename ResourceNameT = Aws::String>
63 ValidationException& WithResourceName(ResourceNameT&& value) { SetResourceName(std::forward<ResourceNameT>(value)); return *this;}
65
67
70 inline ValidationExceptionReason GetReason() const { return m_reason; }
71 inline bool ReasonHasBeenSet() const { return m_reasonHasBeenSet; }
72 inline void SetReason(ValidationExceptionReason value) { m_reasonHasBeenSet = true; m_reason = value; }
73 inline ValidationException& WithReason(ValidationExceptionReason value) { SetReason(value); return *this;}
75
77
81 inline const Aws::Vector<ValidationExceptionField>& GetFieldList() const { return m_fieldList; }
82 inline bool FieldListHasBeenSet() const { return m_fieldListHasBeenSet; }
83 template<typename FieldListT = Aws::Vector<ValidationExceptionField>>
84 void SetFieldList(FieldListT&& value) { m_fieldListHasBeenSet = true; m_fieldList = std::forward<FieldListT>(value); }
85 template<typename FieldListT = Aws::Vector<ValidationExceptionField>>
86 ValidationException& WithFieldList(FieldListT&& value) { SetFieldList(std::forward<FieldListT>(value)); return *this;}
87 template<typename FieldListT = ValidationExceptionField>
88 ValidationException& AddFieldList(FieldListT&& value) { m_fieldListHasBeenSet = true; m_fieldList.emplace_back(std::forward<FieldListT>(value)); return *this; }
90 private:
91
92 Aws::String m_message;
93 bool m_messageHasBeenSet = false;
94
95 Aws::String m_resourceName;
96 bool m_resourceNameHasBeenSet = false;
97
99 bool m_reasonHasBeenSet = false;
100
102 bool m_fieldListHasBeenSet = false;
103 };
104
105} // namespace Model
106} // namespace Invoicing
107} // namespace Aws
AWS_INVOICING_API Aws::Utils::Json::JsonValue Jsonize() const
ValidationException & WithResourceName(ResourceNameT &&value)
ValidationException & AddFieldList(FieldListT &&value)
ValidationException & WithReason(ValidationExceptionReason value)
AWS_INVOICING_API ValidationException(Aws::Utils::Json::JsonView jsonValue)
const Aws::Vector< ValidationExceptionField > & GetFieldList() const
ValidationException & WithFieldList(FieldListT &&value)
void SetReason(ValidationExceptionReason value)
AWS_INVOICING_API ValidationException()=default
AWS_INVOICING_API ValidationException & operator=(Aws::Utils::Json::JsonView jsonValue)
ValidationExceptionReason GetReason() const
ValidationException & WithMessage(MessageT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue