AWS SDK for C++

AWS SDK for C++ Version 1.11.741

Loading...
Searching...
No Matches
Condition.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSVector.h>
8#include <aws/pinpoint/Pinpoint_EXPORTS.h>
9#include <aws/pinpoint/model/Operator.h>
10#include <aws/pinpoint/model/SimpleCondition.h>
11
12#include <utility>
13
14namespace Aws {
15namespace Utils {
16namespace Json {
17class JsonValue;
18class JsonView;
19} // namespace Json
20} // namespace Utils
21namespace Pinpoint {
22namespace Model {
23
30class Condition {
31 public:
32 AWS_PINPOINT_API Condition() = default;
33 AWS_PINPOINT_API Condition(Aws::Utils::Json::JsonView jsonValue);
34 AWS_PINPOINT_API Condition& operator=(Aws::Utils::Json::JsonView jsonValue);
35 AWS_PINPOINT_API Aws::Utils::Json::JsonValue Jsonize() const;
36
38
41 inline const Aws::Vector<SimpleCondition>& GetConditions() const { return m_conditions; }
42 inline bool ConditionsHasBeenSet() const { return m_conditionsHasBeenSet; }
43 template <typename ConditionsT = Aws::Vector<SimpleCondition>>
44 void SetConditions(ConditionsT&& value) {
45 m_conditionsHasBeenSet = true;
46 m_conditions = std::forward<ConditionsT>(value);
47 }
48 template <typename ConditionsT = Aws::Vector<SimpleCondition>>
49 Condition& WithConditions(ConditionsT&& value) {
50 SetConditions(std::forward<ConditionsT>(value));
51 return *this;
52 }
53 template <typename ConditionsT = SimpleCondition>
54 Condition& AddConditions(ConditionsT&& value) {
55 m_conditionsHasBeenSet = true;
56 m_conditions.emplace_back(std::forward<ConditionsT>(value));
57 return *this;
58 }
60
62
67 inline Operator GetOperator() const { return m_operator; }
68 inline bool OperatorHasBeenSet() const { return m_operatorHasBeenSet; }
69 inline void SetOperator(Operator value) {
70 m_operatorHasBeenSet = true;
71 m_operator = value;
72 }
74 SetOperator(value);
75 return *this;
76 }
78 private:
80
81 Operator m_operator{Operator::NOT_SET};
82 bool m_conditionsHasBeenSet = false;
83 bool m_operatorHasBeenSet = false;
84};
85
86} // namespace Model
87} // namespace Pinpoint
88} // namespace Aws
Condition & AddConditions(ConditionsT &&value)
Definition Condition.h:54
AWS_PINPOINT_API Aws::Utils::Json::JsonValue Jsonize() const
AWS_PINPOINT_API Condition & operator=(Aws::Utils::Json::JsonView jsonValue)
Condition & WithConditions(ConditionsT &&value)
Definition Condition.h:49
Condition & WithOperator(Operator value)
Definition Condition.h:73
const Aws::Vector< SimpleCondition > & GetConditions() const
Definition Condition.h:41
AWS_PINPOINT_API Condition(Aws::Utils::Json::JsonView jsonValue)
AWS_PINPOINT_API Condition()=default
void SetConditions(ConditionsT &&value)
Definition Condition.h:44
void SetOperator(Operator value)
Definition Condition.h:69
Operator GetOperator() const
Definition Condition.h:67
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue