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

Sends an input to an IoT Events detector.

See Also:

AWS * API Reference

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

The name of the IoT Events input.

*/ inline const Aws::String& GetInputName() const{ return m_inputName; } /** *

The name of the IoT Events input.

*/ inline bool InputNameHasBeenSet() const { return m_inputNameHasBeenSet; } /** *

The name of the IoT Events input.

*/ inline void SetInputName(const Aws::String& value) { m_inputNameHasBeenSet = true; m_inputName = value; } /** *

The name of the IoT Events input.

*/ inline void SetInputName(Aws::String&& value) { m_inputNameHasBeenSet = true; m_inputName = std::move(value); } /** *

The name of the IoT Events input.

*/ inline void SetInputName(const char* value) { m_inputNameHasBeenSet = true; m_inputName.assign(value); } /** *

The name of the IoT Events input.

*/ inline IotEventsAction& WithInputName(const Aws::String& value) { SetInputName(value); return *this;} /** *

The name of the IoT Events input.

*/ inline IotEventsAction& WithInputName(Aws::String&& value) { SetInputName(std::move(value)); return *this;} /** *

The name of the IoT Events input.

*/ inline IotEventsAction& WithInputName(const char* value) { SetInputName(value); return *this;} /** *

The ID of the message. The default messageId is a new UUID * value.

When batchMode is true, you can't * specify a messageId--a new UUID value will be assigned.

*

Assign a value to this property to ensure that only one input (message) with * a given messageId will be processed by an IoT Events detector.

*/ inline const Aws::String& GetMessageId() const{ return m_messageId; } /** *

The ID of the message. The default messageId is a new UUID * value.

When batchMode is true, you can't * specify a messageId--a new UUID value will be assigned.

*

Assign a value to this property to ensure that only one input (message) with * a given messageId will be processed by an IoT Events detector.

*/ inline bool MessageIdHasBeenSet() const { return m_messageIdHasBeenSet; } /** *

The ID of the message. The default messageId is a new UUID * value.

When batchMode is true, you can't * specify a messageId--a new UUID value will be assigned.

*

Assign a value to this property to ensure that only one input (message) with * a given messageId will be processed by an IoT Events detector.

*/ inline void SetMessageId(const Aws::String& value) { m_messageIdHasBeenSet = true; m_messageId = value; } /** *

The ID of the message. The default messageId is a new UUID * value.

When batchMode is true, you can't * specify a messageId--a new UUID value will be assigned.

*

Assign a value to this property to ensure that only one input (message) with * a given messageId will be processed by an IoT Events detector.

*/ inline void SetMessageId(Aws::String&& value) { m_messageIdHasBeenSet = true; m_messageId = std::move(value); } /** *

The ID of the message. The default messageId is a new UUID * value.

When batchMode is true, you can't * specify a messageId--a new UUID value will be assigned.

*

Assign a value to this property to ensure that only one input (message) with * a given messageId will be processed by an IoT Events detector.

*/ inline void SetMessageId(const char* value) { m_messageIdHasBeenSet = true; m_messageId.assign(value); } /** *

The ID of the message. The default messageId is a new UUID * value.

When batchMode is true, you can't * specify a messageId--a new UUID value will be assigned.

*

Assign a value to this property to ensure that only one input (message) with * a given messageId will be processed by an IoT Events detector.

*/ inline IotEventsAction& WithMessageId(const Aws::String& value) { SetMessageId(value); return *this;} /** *

The ID of the message. The default messageId is a new UUID * value.

When batchMode is true, you can't * specify a messageId--a new UUID value will be assigned.

*

Assign a value to this property to ensure that only one input (message) with * a given messageId will be processed by an IoT Events detector.

*/ inline IotEventsAction& WithMessageId(Aws::String&& value) { SetMessageId(std::move(value)); return *this;} /** *

The ID of the message. The default messageId is a new UUID * value.

When batchMode is true, you can't * specify a messageId--a new UUID value will be assigned.

*

Assign a value to this property to ensure that only one input (message) with * a given messageId will be processed by an IoT Events detector.

*/ inline IotEventsAction& WithMessageId(const char* value) { SetMessageId(value); return *this;} /** *

Whether to process the event actions as a batch. The default value is * false.

When batchMode is true, you * can't specify a messageId.

When batchMode is * true and the rule SQL statement evaluates to an Array, each Array * element is treated as a separate message when it's sent to IoT Events by calling * * BatchPutMessage . The resulting array can't have more than 10 * messages.

*/ inline bool GetBatchMode() const{ return m_batchMode; } /** *

Whether to process the event actions as a batch. The default value is * false.

When batchMode is true, you * can't specify a messageId.

When batchMode is * true and the rule SQL statement evaluates to an Array, each Array * element is treated as a separate message when it's sent to IoT Events by calling * * BatchPutMessage . The resulting array can't have more than 10 * messages.

*/ inline bool BatchModeHasBeenSet() const { return m_batchModeHasBeenSet; } /** *

Whether to process the event actions as a batch. The default value is * false.

When batchMode is true, you * can't specify a messageId.

When batchMode is * true and the rule SQL statement evaluates to an Array, each Array * element is treated as a separate message when it's sent to IoT Events by calling * * BatchPutMessage . The resulting array can't have more than 10 * messages.

*/ inline void SetBatchMode(bool value) { m_batchModeHasBeenSet = true; m_batchMode = value; } /** *

Whether to process the event actions as a batch. The default value is * false.

When batchMode is true, you * can't specify a messageId.

When batchMode is * true and the rule SQL statement evaluates to an Array, each Array * element is treated as a separate message when it's sent to IoT Events by calling * * BatchPutMessage . The resulting array can't have more than 10 * messages.

*/ inline IotEventsAction& WithBatchMode(bool value) { SetBatchMode(value); return *this;} /** *

The ARN of the role that grants IoT permission to send an input to an IoT * Events detector. ("Action":"iotevents:BatchPutMessage").

*/ inline const Aws::String& GetRoleArn() const{ return m_roleArn; } /** *

The ARN of the role that grants IoT permission to send an input to an IoT * Events detector. ("Action":"iotevents:BatchPutMessage").

*/ inline bool RoleArnHasBeenSet() const { return m_roleArnHasBeenSet; } /** *

The ARN of the role that grants IoT permission to send an input to an IoT * Events detector. ("Action":"iotevents:BatchPutMessage").

*/ inline void SetRoleArn(const Aws::String& value) { m_roleArnHasBeenSet = true; m_roleArn = value; } /** *

The ARN of the role that grants IoT permission to send an input to an IoT * Events detector. ("Action":"iotevents:BatchPutMessage").

*/ inline void SetRoleArn(Aws::String&& value) { m_roleArnHasBeenSet = true; m_roleArn = std::move(value); } /** *

The ARN of the role that grants IoT permission to send an input to an IoT * Events detector. ("Action":"iotevents:BatchPutMessage").

*/ inline void SetRoleArn(const char* value) { m_roleArnHasBeenSet = true; m_roleArn.assign(value); } /** *

The ARN of the role that grants IoT permission to send an input to an IoT * Events detector. ("Action":"iotevents:BatchPutMessage").

*/ inline IotEventsAction& WithRoleArn(const Aws::String& value) { SetRoleArn(value); return *this;} /** *

The ARN of the role that grants IoT permission to send an input to an IoT * Events detector. ("Action":"iotevents:BatchPutMessage").

*/ inline IotEventsAction& WithRoleArn(Aws::String&& value) { SetRoleArn(std::move(value)); return *this;} /** *

The ARN of the role that grants IoT permission to send an input to an IoT * Events detector. ("Action":"iotevents:BatchPutMessage").

*/ inline IotEventsAction& WithRoleArn(const char* value) { SetRoleArn(value); return *this;} private: Aws::String m_inputName; bool m_inputNameHasBeenSet = false; Aws::String m_messageId; bool m_messageIdHasBeenSet = false; bool m_batchMode; bool m_batchModeHasBeenSet = false; Aws::String m_roleArn; bool m_roleArnHasBeenSet = false; }; } // namespace Model } // namespace IoT } // namespace Aws