AWS SDK for C++

AWS SDK for C++ Version 1.11.751

Loading...
Searching...
No Matches
LiteralOptions.h
1
6#pragma once
7#include <aws/cloudsearch/CloudSearch_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSStreamFwd.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10
11#include <utility>
12
13namespace Aws {
14namespace Utils {
15namespace Xml {
16class XmlNode;
17} // namespace Xml
18} // namespace Utils
19namespace CloudSearch {
20namespace Model {
21
30 public:
31 AWS_CLOUDSEARCH_API LiteralOptions() = default;
32 AWS_CLOUDSEARCH_API LiteralOptions(const Aws::Utils::Xml::XmlNode& xmlNode);
33 AWS_CLOUDSEARCH_API LiteralOptions& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
34
35 AWS_CLOUDSEARCH_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const;
36 AWS_CLOUDSEARCH_API void OutputToStream(Aws::OStream& oStream, const char* location) const;
37
39
42 inline const Aws::String& GetDefaultValue() const { return m_defaultValue; }
43 inline bool DefaultValueHasBeenSet() const { return m_defaultValueHasBeenSet; }
44 template <typename DefaultValueT = Aws::String>
45 void SetDefaultValue(DefaultValueT&& value) {
46 m_defaultValueHasBeenSet = true;
47 m_defaultValue = std::forward<DefaultValueT>(value);
48 }
49 template <typename DefaultValueT = Aws::String>
50 LiteralOptions& WithDefaultValue(DefaultValueT&& value) {
51 SetDefaultValue(std::forward<DefaultValueT>(value));
52 return *this;
53 }
55
57
58 inline const Aws::String& GetSourceField() const { return m_sourceField; }
59 inline bool SourceFieldHasBeenSet() const { return m_sourceFieldHasBeenSet; }
60 template <typename SourceFieldT = Aws::String>
61 void SetSourceField(SourceFieldT&& value) {
62 m_sourceFieldHasBeenSet = true;
63 m_sourceField = std::forward<SourceFieldT>(value);
64 }
65 template <typename SourceFieldT = Aws::String>
66 LiteralOptions& WithSourceField(SourceFieldT&& value) {
67 SetSourceField(std::forward<SourceFieldT>(value));
68 return *this;
69 }
71
73
76 inline bool GetFacetEnabled() const { return m_facetEnabled; }
77 inline bool FacetEnabledHasBeenSet() const { return m_facetEnabledHasBeenSet; }
78 inline void SetFacetEnabled(bool value) {
79 m_facetEnabledHasBeenSet = true;
80 m_facetEnabled = value;
81 }
82 inline LiteralOptions& WithFacetEnabled(bool value) {
83 SetFacetEnabled(value);
84 return *this;
85 }
87
89
92 inline bool GetSearchEnabled() const { return m_searchEnabled; }
93 inline bool SearchEnabledHasBeenSet() const { return m_searchEnabledHasBeenSet; }
94 inline void SetSearchEnabled(bool value) {
95 m_searchEnabledHasBeenSet = true;
96 m_searchEnabled = value;
97 }
98 inline LiteralOptions& WithSearchEnabled(bool value) {
99 SetSearchEnabled(value);
100 return *this;
101 }
103
105
108 inline bool GetReturnEnabled() const { return m_returnEnabled; }
109 inline bool ReturnEnabledHasBeenSet() const { return m_returnEnabledHasBeenSet; }
110 inline void SetReturnEnabled(bool value) {
111 m_returnEnabledHasBeenSet = true;
112 m_returnEnabled = value;
113 }
114 inline LiteralOptions& WithReturnEnabled(bool value) {
115 SetReturnEnabled(value);
116 return *this;
117 }
119
121
124 inline bool GetSortEnabled() const { return m_sortEnabled; }
125 inline bool SortEnabledHasBeenSet() const { return m_sortEnabledHasBeenSet; }
126 inline void SetSortEnabled(bool value) {
127 m_sortEnabledHasBeenSet = true;
128 m_sortEnabled = value;
129 }
130 inline LiteralOptions& WithSortEnabled(bool value) {
131 SetSortEnabled(value);
132 return *this;
133 }
135 private:
136 Aws::String m_defaultValue;
137
138 Aws::String m_sourceField;
139
140 bool m_facetEnabled{false};
141
142 bool m_searchEnabled{false};
143
144 bool m_returnEnabled{false};
145
146 bool m_sortEnabled{false};
147 bool m_defaultValueHasBeenSet = false;
148 bool m_sourceFieldHasBeenSet = false;
149 bool m_facetEnabledHasBeenSet = false;
150 bool m_searchEnabledHasBeenSet = false;
151 bool m_returnEnabledHasBeenSet = false;
152 bool m_sortEnabledHasBeenSet = false;
153};
154
155} // namespace Model
156} // namespace CloudSearch
157} // namespace Aws
LiteralOptions & WithSortEnabled(bool value)
AWS_CLOUDSEARCH_API void OutputToStream(Aws::OStream &ostream, const char *location, unsigned index, const char *locationValue) const
void SetDefaultValue(DefaultValueT &&value)
LiteralOptions & WithReturnEnabled(bool value)
LiteralOptions & WithSourceField(SourceFieldT &&value)
LiteralOptions & WithFacetEnabled(bool value)
LiteralOptions & WithSearchEnabled(bool value)
AWS_CLOUDSEARCH_API void OutputToStream(Aws::OStream &oStream, const char *location) const
AWS_CLOUDSEARCH_API LiteralOptions(const Aws::Utils::Xml::XmlNode &xmlNode)
LiteralOptions & WithDefaultValue(DefaultValueT &&value)
void SetSourceField(SourceFieldT &&value)
AWS_CLOUDSEARCH_API LiteralOptions()=default
const Aws::String & GetSourceField() const
AWS_CLOUDSEARCH_API LiteralOptions & operator=(const Aws::Utils::Xml::XmlNode &xmlNode)
const Aws::String & GetDefaultValue() const
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::basic_ostream< char, std::char_traits< char > > OStream