AWS SDK for C++

AWS SDK for C++ Version 1.11.941

Loading...
Searching...
No Matches
ArraySetting.h
1
6#pragma once
7#include <aws/cloudextensions/CloudExtensions_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSAllocator.h>
9
10#include <utility>
11
12namespace Aws {
13namespace Utils {
14namespace Json {
15class JsonValue;
16class JsonView;
17} // namespace Json
18} // namespace Utils
19namespace CloudExtensions {
20namespace Model {
21class SettingDefinition;
22
30 public:
31 AWS_CLOUDEXTENSIONS_API ArraySetting() = default;
32 AWS_CLOUDEXTENSIONS_API ArraySetting(Aws::Utils::Json::JsonView jsonValue);
33 AWS_CLOUDEXTENSIONS_API ArraySetting& operator=(Aws::Utils::Json::JsonView jsonValue);
34 AWS_CLOUDEXTENSIONS_API Aws::Utils::Json::JsonValue Jsonize() const;
35
37
40 inline int GetMinLength() const { return m_minLength; }
41 inline bool MinLengthHasBeenSet() const { return m_minLengthHasBeenSet; }
42 inline void SetMinLength(int value) {
43 m_minLengthHasBeenSet = true;
44 m_minLength = value;
45 }
46 inline ArraySetting& WithMinLength(int value) {
47 SetMinLength(value);
48 return *this;
49 }
51
53
57 inline int GetMaxLength() const { return m_maxLength; }
58 inline bool MaxLengthHasBeenSet() const { return m_maxLengthHasBeenSet; }
59 inline void SetMaxLength(int value) {
60 m_maxLengthHasBeenSet = true;
61 m_maxLength = value;
62 }
63 inline ArraySetting& WithMaxLength(int value) {
64 SetMaxLength(value);
65 return *this;
66 }
68
70
73 inline const SettingDefinition& GetItemDefinition() const { return *m_itemDefinition; }
74 inline bool ItemDefinitionHasBeenSet() const { return m_itemDefinitionHasBeenSet; }
75 template <typename ItemDefinitionT = SettingDefinition>
76 void SetItemDefinition(ItemDefinitionT&& value) {
77 m_itemDefinitionHasBeenSet = true;
78 m_itemDefinition = Aws::MakeShared<SettingDefinition>("ArraySetting", std::forward<ItemDefinitionT>(value));
79 }
80 template <typename ItemDefinitionT = SettingDefinition>
81 ArraySetting& WithItemDefinition(ItemDefinitionT&& value) {
82 SetItemDefinition(std::forward<ItemDefinitionT>(value));
83 return *this;
84 }
86 private:
87 int m_minLength{0};
88
89 int m_maxLength{0};
90
91 std::shared_ptr<SettingDefinition> m_itemDefinition;
92 bool m_minLengthHasBeenSet = false;
93 bool m_maxLengthHasBeenSet = false;
94 bool m_itemDefinitionHasBeenSet = false;
95};
96
97} // namespace Model
98} // namespace CloudExtensions
99} // namespace Aws
AWS_CLOUDEXTENSIONS_API ArraySetting & operator=(Aws::Utils::Json::JsonView jsonValue)
AWS_CLOUDEXTENSIONS_API ArraySetting()=default
AWS_CLOUDEXTENSIONS_API Aws::Utils::Json::JsonValue Jsonize() const
ArraySetting & WithMinLength(int value)
void SetItemDefinition(ItemDefinitionT &&value)
AWS_CLOUDEXTENSIONS_API ArraySetting(Aws::Utils::Json::JsonView jsonValue)
ArraySetting & WithMaxLength(int value)
ArraySetting & WithItemDefinition(ItemDefinitionT &&value)
const SettingDefinition & GetItemDefinition() const
std::shared_ptr< T > MakeShared(const char *allocationTag, ArgTypes &&... args)
Aws::Utils::Json::JsonValue JsonValue