1 /**
2  * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3  * SPDX-License-Identifier: Apache-2.0.
4  */
5 
6 #pragma once
7 #include <aws/pinpoint/Pinpoint_EXPORTS.h>
8 #include <aws/pinpoint/model/AttributeType.h>
9 #include <aws/core/utils/memory/stl/AWSVector.h>
10 #include <aws/core/utils/memory/stl/AWSString.h>
11 #include <utility>
12 
13 namespace Aws
14 {
15 namespace Utils
16 {
17 namespace Json
18 {
19   class JsonValue;
20   class JsonView;
21 } // namespace Json
22 } // namespace Utils
23 namespace Pinpoint
24 {
25 namespace Model
26 {
27 
28   /**
29    * <p>Specifies attribute-based criteria for including or excluding endpoints from
30    * a segment.</p><p><h3>See Also:</h3>   <a
31    * href="http://docs.aws.amazon.com/goto/WebAPI/pinpoint-2016-12-01/AttributeDimension">AWS
32    * API Reference</a></p>
33    */
34   class AWS_PINPOINT_API AttributeDimension
35   {
36   public:
37     AttributeDimension();
38     AttributeDimension(Aws::Utils::Json::JsonView jsonValue);
39     AttributeDimension& operator=(Aws::Utils::Json::JsonView jsonValue);
40     Aws::Utils::Json::JsonValue Jsonize() const;
41 
42 
43     /**
44      * <p>The type of segment dimension to use. Valid values are: <ul><li>INCLUSIVE -
45      * endpoints that have attributes matching the values are included in the
46      * segment.</li><li>EXCLUSIVE - endpoints that have attributes matching the values
47      * are excluded in the segment.</li><li>CONTAINS - endpoints that have attributes'
48      * substrings match the values are included in the segment.</li><li>BEFORE -
49      * endpoints with attributes read as ISO_INSTANT datetimes before the value are
50      * included in the segment.</li><li>AFTER - endpoints with attributes read as
51      * ISO_INSTANT datetimes after the value are included in the segment.</li><li>ON -
52      * endpoints with attributes read as ISO_INSTANT dates on the value are included in
53      * the segment. Time is ignored in this comparison.</li><li>BETWEEN - endpoints
54      * with attributes read as ISO_INSTANT datetimes between the values are included in
55      * the segment.</li></p>
56      */
GetAttributeType()57     inline const AttributeType& GetAttributeType() const{ return m_attributeType; }
58 
59     /**
60      * <p>The type of segment dimension to use. Valid values are: <ul><li>INCLUSIVE -
61      * endpoints that have attributes matching the values are included in the
62      * segment.</li><li>EXCLUSIVE - endpoints that have attributes matching the values
63      * are excluded in the segment.</li><li>CONTAINS - endpoints that have attributes'
64      * substrings match the values are included in the segment.</li><li>BEFORE -
65      * endpoints with attributes read as ISO_INSTANT datetimes before the value are
66      * included in the segment.</li><li>AFTER - endpoints with attributes read as
67      * ISO_INSTANT datetimes after the value are included in the segment.</li><li>ON -
68      * endpoints with attributes read as ISO_INSTANT dates on the value are included in
69      * the segment. Time is ignored in this comparison.</li><li>BETWEEN - endpoints
70      * with attributes read as ISO_INSTANT datetimes between the values are included in
71      * the segment.</li></p>
72      */
AttributeTypeHasBeenSet()73     inline bool AttributeTypeHasBeenSet() const { return m_attributeTypeHasBeenSet; }
74 
75     /**
76      * <p>The type of segment dimension to use. Valid values are: <ul><li>INCLUSIVE -
77      * endpoints that have attributes matching the values are included in the
78      * segment.</li><li>EXCLUSIVE - endpoints that have attributes matching the values
79      * are excluded in the segment.</li><li>CONTAINS - endpoints that have attributes'
80      * substrings match the values are included in the segment.</li><li>BEFORE -
81      * endpoints with attributes read as ISO_INSTANT datetimes before the value are
82      * included in the segment.</li><li>AFTER - endpoints with attributes read as
83      * ISO_INSTANT datetimes after the value are included in the segment.</li><li>ON -
84      * endpoints with attributes read as ISO_INSTANT dates on the value are included in
85      * the segment. Time is ignored in this comparison.</li><li>BETWEEN - endpoints
86      * with attributes read as ISO_INSTANT datetimes between the values are included in
87      * the segment.</li></p>
88      */
SetAttributeType(const AttributeType & value)89     inline void SetAttributeType(const AttributeType& value) { m_attributeTypeHasBeenSet = true; m_attributeType = value; }
90 
91     /**
92      * <p>The type of segment dimension to use. Valid values are: <ul><li>INCLUSIVE -
93      * endpoints that have attributes matching the values are included in the
94      * segment.</li><li>EXCLUSIVE - endpoints that have attributes matching the values
95      * are excluded in the segment.</li><li>CONTAINS - endpoints that have attributes'
96      * substrings match the values are included in the segment.</li><li>BEFORE -
97      * endpoints with attributes read as ISO_INSTANT datetimes before the value are
98      * included in the segment.</li><li>AFTER - endpoints with attributes read as
99      * ISO_INSTANT datetimes after the value are included in the segment.</li><li>ON -
100      * endpoints with attributes read as ISO_INSTANT dates on the value are included in
101      * the segment. Time is ignored in this comparison.</li><li>BETWEEN - endpoints
102      * with attributes read as ISO_INSTANT datetimes between the values are included in
103      * the segment.</li></p>
104      */
SetAttributeType(AttributeType && value)105     inline void SetAttributeType(AttributeType&& value) { m_attributeTypeHasBeenSet = true; m_attributeType = std::move(value); }
106 
107     /**
108      * <p>The type of segment dimension to use. Valid values are: <ul><li>INCLUSIVE -
109      * endpoints that have attributes matching the values are included in the
110      * segment.</li><li>EXCLUSIVE - endpoints that have attributes matching the values
111      * are excluded in the segment.</li><li>CONTAINS - endpoints that have attributes'
112      * substrings match the values are included in the segment.</li><li>BEFORE -
113      * endpoints with attributes read as ISO_INSTANT datetimes before the value are
114      * included in the segment.</li><li>AFTER - endpoints with attributes read as
115      * ISO_INSTANT datetimes after the value are included in the segment.</li><li>ON -
116      * endpoints with attributes read as ISO_INSTANT dates on the value are included in
117      * the segment. Time is ignored in this comparison.</li><li>BETWEEN - endpoints
118      * with attributes read as ISO_INSTANT datetimes between the values are included in
119      * the segment.</li></p>
120      */
WithAttributeType(const AttributeType & value)121     inline AttributeDimension& WithAttributeType(const AttributeType& value) { SetAttributeType(value); return *this;}
122 
123     /**
124      * <p>The type of segment dimension to use. Valid values are: <ul><li>INCLUSIVE -
125      * endpoints that have attributes matching the values are included in the
126      * segment.</li><li>EXCLUSIVE - endpoints that have attributes matching the values
127      * are excluded in the segment.</li><li>CONTAINS - endpoints that have attributes'
128      * substrings match the values are included in the segment.</li><li>BEFORE -
129      * endpoints with attributes read as ISO_INSTANT datetimes before the value are
130      * included in the segment.</li><li>AFTER - endpoints with attributes read as
131      * ISO_INSTANT datetimes after the value are included in the segment.</li><li>ON -
132      * endpoints with attributes read as ISO_INSTANT dates on the value are included in
133      * the segment. Time is ignored in this comparison.</li><li>BETWEEN - endpoints
134      * with attributes read as ISO_INSTANT datetimes between the values are included in
135      * the segment.</li></p>
136      */
WithAttributeType(AttributeType && value)137     inline AttributeDimension& WithAttributeType(AttributeType&& value) { SetAttributeType(std::move(value)); return *this;}
138 
139 
140     /**
141      * <p>The criteria values to use for the segment dimension. Depending on the value
142      * of the AttributeType property, endpoints are included or excluded from the
143      * segment if their attribute values match the criteria values.</p>
144      */
GetValues()145     inline const Aws::Vector<Aws::String>& GetValues() const{ return m_values; }
146 
147     /**
148      * <p>The criteria values to use for the segment dimension. Depending on the value
149      * of the AttributeType property, endpoints are included or excluded from the
150      * segment if their attribute values match the criteria values.</p>
151      */
ValuesHasBeenSet()152     inline bool ValuesHasBeenSet() const { return m_valuesHasBeenSet; }
153 
154     /**
155      * <p>The criteria values to use for the segment dimension. Depending on the value
156      * of the AttributeType property, endpoints are included or excluded from the
157      * segment if their attribute values match the criteria values.</p>
158      */
SetValues(const Aws::Vector<Aws::String> & value)159     inline void SetValues(const Aws::Vector<Aws::String>& value) { m_valuesHasBeenSet = true; m_values = value; }
160 
161     /**
162      * <p>The criteria values to use for the segment dimension. Depending on the value
163      * of the AttributeType property, endpoints are included or excluded from the
164      * segment if their attribute values match the criteria values.</p>
165      */
SetValues(Aws::Vector<Aws::String> && value)166     inline void SetValues(Aws::Vector<Aws::String>&& value) { m_valuesHasBeenSet = true; m_values = std::move(value); }
167 
168     /**
169      * <p>The criteria values to use for the segment dimension. Depending on the value
170      * of the AttributeType property, endpoints are included or excluded from the
171      * segment if their attribute values match the criteria values.</p>
172      */
WithValues(const Aws::Vector<Aws::String> & value)173     inline AttributeDimension& WithValues(const Aws::Vector<Aws::String>& value) { SetValues(value); return *this;}
174 
175     /**
176      * <p>The criteria values to use for the segment dimension. Depending on the value
177      * of the AttributeType property, endpoints are included or excluded from the
178      * segment if their attribute values match the criteria values.</p>
179      */
WithValues(Aws::Vector<Aws::String> && value)180     inline AttributeDimension& WithValues(Aws::Vector<Aws::String>&& value) { SetValues(std::move(value)); return *this;}
181 
182     /**
183      * <p>The criteria values to use for the segment dimension. Depending on the value
184      * of the AttributeType property, endpoints are included or excluded from the
185      * segment if their attribute values match the criteria values.</p>
186      */
AddValues(const Aws::String & value)187     inline AttributeDimension& AddValues(const Aws::String& value) { m_valuesHasBeenSet = true; m_values.push_back(value); return *this; }
188 
189     /**
190      * <p>The criteria values to use for the segment dimension. Depending on the value
191      * of the AttributeType property, endpoints are included or excluded from the
192      * segment if their attribute values match the criteria values.</p>
193      */
AddValues(Aws::String && value)194     inline AttributeDimension& AddValues(Aws::String&& value) { m_valuesHasBeenSet = true; m_values.push_back(std::move(value)); return *this; }
195 
196     /**
197      * <p>The criteria values to use for the segment dimension. Depending on the value
198      * of the AttributeType property, endpoints are included or excluded from the
199      * segment if their attribute values match the criteria values.</p>
200      */
AddValues(const char * value)201     inline AttributeDimension& AddValues(const char* value) { m_valuesHasBeenSet = true; m_values.push_back(value); return *this; }
202 
203   private:
204 
205     AttributeType m_attributeType;
206     bool m_attributeTypeHasBeenSet;
207 
208     Aws::Vector<Aws::String> m_values;
209     bool m_valuesHasBeenSet;
210   };
211 
212 } // namespace Model
213 } // namespace Pinpoint
214 } // namespace Aws
215