/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace IoTEvents { namespace Model { /** *

Specifies the actions to be performed when the * condition evaluates to TRUE.

See Also:

AWS API * Reference

*/ class Event { public: AWS_IOTEVENTS_API Event(); AWS_IOTEVENTS_API Event(Aws::Utils::Json::JsonView jsonValue); AWS_IOTEVENTS_API Event& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_IOTEVENTS_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

The name of the event.

*/ inline const Aws::String& GetEventName() const{ return m_eventName; } /** *

The name of the event.

*/ inline bool EventNameHasBeenSet() const { return m_eventNameHasBeenSet; } /** *

The name of the event.

*/ inline void SetEventName(const Aws::String& value) { m_eventNameHasBeenSet = true; m_eventName = value; } /** *

The name of the event.

*/ inline void SetEventName(Aws::String&& value) { m_eventNameHasBeenSet = true; m_eventName = std::move(value); } /** *

The name of the event.

*/ inline void SetEventName(const char* value) { m_eventNameHasBeenSet = true; m_eventName.assign(value); } /** *

The name of the event.

*/ inline Event& WithEventName(const Aws::String& value) { SetEventName(value); return *this;} /** *

The name of the event.

*/ inline Event& WithEventName(Aws::String&& value) { SetEventName(std::move(value)); return *this;} /** *

The name of the event.

*/ inline Event& WithEventName(const char* value) { SetEventName(value); return *this;} /** *

Optional. The Boolean expression that, when TRUE, causes the * actions to be performed. If not present, the actions are performed * (=TRUE). If the expression result is not a Boolean value, the actions are not * performed (=FALSE).

*/ inline const Aws::String& GetCondition() const{ return m_condition; } /** *

Optional. The Boolean expression that, when TRUE, causes the * actions to be performed. If not present, the actions are performed * (=TRUE). If the expression result is not a Boolean value, the actions are not * performed (=FALSE).

*/ inline bool ConditionHasBeenSet() const { return m_conditionHasBeenSet; } /** *

Optional. The Boolean expression that, when TRUE, causes the * actions to be performed. If not present, the actions are performed * (=TRUE). If the expression result is not a Boolean value, the actions are not * performed (=FALSE).

*/ inline void SetCondition(const Aws::String& value) { m_conditionHasBeenSet = true; m_condition = value; } /** *

Optional. The Boolean expression that, when TRUE, causes the * actions to be performed. If not present, the actions are performed * (=TRUE). If the expression result is not a Boolean value, the actions are not * performed (=FALSE).

*/ inline void SetCondition(Aws::String&& value) { m_conditionHasBeenSet = true; m_condition = std::move(value); } /** *

Optional. The Boolean expression that, when TRUE, causes the * actions to be performed. If not present, the actions are performed * (=TRUE). If the expression result is not a Boolean value, the actions are not * performed (=FALSE).

*/ inline void SetCondition(const char* value) { m_conditionHasBeenSet = true; m_condition.assign(value); } /** *

Optional. The Boolean expression that, when TRUE, causes the * actions to be performed. If not present, the actions are performed * (=TRUE). If the expression result is not a Boolean value, the actions are not * performed (=FALSE).

*/ inline Event& WithCondition(const Aws::String& value) { SetCondition(value); return *this;} /** *

Optional. The Boolean expression that, when TRUE, causes the * actions to be performed. If not present, the actions are performed * (=TRUE). If the expression result is not a Boolean value, the actions are not * performed (=FALSE).

*/ inline Event& WithCondition(Aws::String&& value) { SetCondition(std::move(value)); return *this;} /** *

Optional. The Boolean expression that, when TRUE, causes the * actions to be performed. If not present, the actions are performed * (=TRUE). If the expression result is not a Boolean value, the actions are not * performed (=FALSE).

*/ inline Event& WithCondition(const char* value) { SetCondition(value); return *this;} /** *

The actions to be performed.

*/ inline const Aws::Vector& GetActions() const{ return m_actions; } /** *

The actions to be performed.

*/ inline bool ActionsHasBeenSet() const { return m_actionsHasBeenSet; } /** *

The actions to be performed.

*/ inline void SetActions(const Aws::Vector& value) { m_actionsHasBeenSet = true; m_actions = value; } /** *

The actions to be performed.

*/ inline void SetActions(Aws::Vector&& value) { m_actionsHasBeenSet = true; m_actions = std::move(value); } /** *

The actions to be performed.

*/ inline Event& WithActions(const Aws::Vector& value) { SetActions(value); return *this;} /** *

The actions to be performed.

*/ inline Event& WithActions(Aws::Vector&& value) { SetActions(std::move(value)); return *this;} /** *

The actions to be performed.

*/ inline Event& AddActions(const Action& value) { m_actionsHasBeenSet = true; m_actions.push_back(value); return *this; } /** *

The actions to be performed.

*/ inline Event& AddActions(Action&& value) { m_actionsHasBeenSet = true; m_actions.push_back(std::move(value)); return *this; } private: Aws::String m_eventName; bool m_eventNameHasBeenSet = false; Aws::String m_condition; bool m_conditionHasBeenSet = false; Aws::Vector m_actions; bool m_actionsHasBeenSet = false; }; } // namespace Model } // namespace IoTEvents } // namespace Aws