AWS SDK for C++

AWS SDK for C++ Version 1.11.440

Loading...
Searching...
No Matches
ValidationException.h
1
6#pragma once
7#include <aws/codeguru-security/CodeGuruSecurity_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/codeguru-security/model/ValidationExceptionReason.h>
11#include <aws/codeguru-security/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 CodeGuruSecurity
25{
26namespace Model
27{
28
36 {
37 public:
38 AWS_CODEGURUSECURITY_API ValidationException();
39 AWS_CODEGURUSECURITY_API ValidationException(Aws::Utils::Json::JsonView jsonValue);
40 AWS_CODEGURUSECURITY_API ValidationException& operator=(Aws::Utils::Json::JsonView jsonValue);
41 AWS_CODEGURUSECURITY_API Aws::Utils::Json::JsonValue Jsonize() const;
42
43
45
48 inline const Aws::String& GetErrorCode() const{ return m_errorCode; }
49 inline bool ErrorCodeHasBeenSet() const { return m_errorCodeHasBeenSet; }
50 inline void SetErrorCode(const Aws::String& value) { m_errorCodeHasBeenSet = true; m_errorCode = value; }
51 inline void SetErrorCode(Aws::String&& value) { m_errorCodeHasBeenSet = true; m_errorCode = std::move(value); }
52 inline void SetErrorCode(const char* value) { m_errorCodeHasBeenSet = true; m_errorCode.assign(value); }
53 inline ValidationException& WithErrorCode(const Aws::String& value) { SetErrorCode(value); return *this;}
54 inline ValidationException& WithErrorCode(Aws::String&& value) { SetErrorCode(std::move(value)); return *this;}
55 inline ValidationException& WithErrorCode(const char* value) { SetErrorCode(value); return *this;}
57
59
62 inline const Aws::Vector<ValidationExceptionField>& GetFieldList() const{ return m_fieldList; }
63 inline bool FieldListHasBeenSet() const { return m_fieldListHasBeenSet; }
64 inline void SetFieldList(const Aws::Vector<ValidationExceptionField>& value) { m_fieldListHasBeenSet = true; m_fieldList = value; }
65 inline void SetFieldList(Aws::Vector<ValidationExceptionField>&& value) { m_fieldListHasBeenSet = true; m_fieldList = std::move(value); }
67 inline ValidationException& WithFieldList(Aws::Vector<ValidationExceptionField>&& value) { SetFieldList(std::move(value)); return *this;}
68 inline ValidationException& AddFieldList(const ValidationExceptionField& value) { m_fieldListHasBeenSet = true; m_fieldList.push_back(value); return *this; }
69 inline ValidationException& AddFieldList(ValidationExceptionField&& value) { m_fieldListHasBeenSet = true; m_fieldList.push_back(std::move(value)); return *this; }
71
73
76 inline const Aws::String& GetMessage() const{ return m_message; }
77 inline bool MessageHasBeenSet() const { return m_messageHasBeenSet; }
78 inline void SetMessage(const Aws::String& value) { m_messageHasBeenSet = true; m_message = value; }
79 inline void SetMessage(Aws::String&& value) { m_messageHasBeenSet = true; m_message = std::move(value); }
80 inline void SetMessage(const char* value) { m_messageHasBeenSet = true; m_message.assign(value); }
81 inline ValidationException& WithMessage(const Aws::String& value) { SetMessage(value); return *this;}
82 inline ValidationException& WithMessage(Aws::String&& value) { SetMessage(std::move(value)); return *this;}
83 inline ValidationException& WithMessage(const char* value) { SetMessage(value); return *this;}
85
87
90 inline const ValidationExceptionReason& GetReason() const{ return m_reason; }
91 inline bool ReasonHasBeenSet() const { return m_reasonHasBeenSet; }
92 inline void SetReason(const ValidationExceptionReason& value) { m_reasonHasBeenSet = true; m_reason = value; }
93 inline void SetReason(ValidationExceptionReason&& value) { m_reasonHasBeenSet = true; m_reason = std::move(value); }
94 inline ValidationException& WithReason(const ValidationExceptionReason& value) { SetReason(value); return *this;}
95 inline ValidationException& WithReason(ValidationExceptionReason&& value) { SetReason(std::move(value)); return *this;}
97 private:
98
99 Aws::String m_errorCode;
100 bool m_errorCodeHasBeenSet = false;
101
103 bool m_fieldListHasBeenSet = false;
104
105 Aws::String m_message;
106 bool m_messageHasBeenSet = false;
107
109 bool m_reasonHasBeenSet = false;
110 };
111
112} // namespace Model
113} // namespace CodeGuruSecurity
114} // namespace Aws
ValidationException & WithReason(ValidationExceptionReason &&value)
ValidationException & WithErrorCode(const Aws::String &value)
ValidationException & WithMessage(const Aws::String &value)
void SetReason(ValidationExceptionReason &&value)
ValidationException & WithErrorCode(Aws::String &&value)
AWS_CODEGURUSECURITY_API Aws::Utils::Json::JsonValue Jsonize() const
ValidationException & WithMessage(const char *value)
ValidationException & AddFieldList(const ValidationExceptionField &value)
void SetFieldList(const Aws::Vector< ValidationExceptionField > &value)
ValidationException & WithErrorCode(const char *value)
AWS_CODEGURUSECURITY_API ValidationException(Aws::Utils::Json::JsonView jsonValue)
AWS_CODEGURUSECURITY_API ValidationException & operator=(Aws::Utils::Json::JsonView jsonValue)
const ValidationExceptionReason & GetReason() const
ValidationException & WithFieldList(const Aws::Vector< ValidationExceptionField > &value)
ValidationException & AddFieldList(ValidationExceptionField &&value)
void SetFieldList(Aws::Vector< ValidationExceptionField > &&value)
const Aws::Vector< ValidationExceptionField > & GetFieldList() const
ValidationException & WithFieldList(Aws::Vector< ValidationExceptionField > &&value)
void SetReason(const ValidationExceptionReason &value)
ValidationException & WithMessage(Aws::String &&value)
ValidationException & WithReason(const ValidationExceptionReason &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