AlexaClientSDK  3.0.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
Public Member Functions | List of all members
alexaClientSDK::settings::SettingEventSenderInterface Class Referenceabstract

#include <SettingEventSenderInterface.h>

Inheritance diagram for alexaClientSDK::settings::SettingEventSenderInterface:
Inheritance graph
[legend]

Public Member Functions

virtual ~SettingEventSenderInterface ()=default
 
virtual std::shared_future< bool > sendChangedEvent (const std::string &value)=0
 
virtual std::shared_future< bool > sendReportEvent (const std::string &value)=0
 
virtual std::shared_future< bool > sendStateReportEvent (const std::string &payload)=0
 
virtual void cancel ()=0
 

Constructor & Destructor Documentation

◆ ~SettingEventSenderInterface()

virtual alexaClientSDK::settings::SettingEventSenderInterface::~SettingEventSenderInterface ( )
virtualdefault

Destructor.

Member Function Documentation

◆ cancel()

virtual void alexaClientSDK::settings::SettingEventSenderInterface::cancel ( )
pure virtual

◆ sendChangedEvent()

virtual std::shared_future<bool> alexaClientSDK::settings::SettingEventSenderInterface::sendChangedEvent ( const std::string &  value)
pure virtual

Sends a setting changed event to AVS. This event follows the format:

{
"event": {
"header": {
"namespace": "{eventNamespace}",
"name": "{eventChangedName}",
"messageId": "xxxxx"
},
"payload": {
"{settingName}": yyyyy
}
}
}

The setting specific fields should be specified in a SettingEventMetadata passed as an argument on creation this object.

Parameters
valueThe value of the setting. It should be a valid JSON string value.
Returns
A future expressing if the event has been guaranteed to be sent to AVS.

Implemented in alexaClientSDK::capabilityAgents::doNotDisturb::DoNotDisturbCapabilityAgent, and alexaClientSDK::settings::SettingEventSender.

◆ sendReportEvent()

virtual std::shared_future<bool> alexaClientSDK::settings::SettingEventSenderInterface::sendReportEvent ( const std::string &  value)
pure virtual

Sends a report setting event to AVS.

The setting report event follows the format:

{
"event": {
"header": {
"namespace": "{eventNamespace}",
"name": "{eventReportName}",
"messageId": "xxxxx"
},
"payload": {
"{settingName}": yyyyy
}
}
}

The setting specific fields should be specified in a SettingEventMetadata passed as an argument on creation this object.

Parameters
valueThe value of the setting. It should be a valid JSON string value.
Returns
A future expressing if the event has been guaranteed to be sent to AVS.

Implemented in alexaClientSDK::capabilityAgents::doNotDisturb::DoNotDisturbCapabilityAgent, and alexaClientSDK::settings::SettingEventSender.

◆ sendStateReportEvent()

virtual std::shared_future<bool> alexaClientSDK::settings::SettingEventSenderInterface::sendStateReportEvent ( const std::string &  payload)
pure virtual

Sends a state report event to AVS.

The setting state report event follows the format:

{
"event": {
"header": {
"namespace": "{eventNamespace}",
"name": "{eventReportName}",
"messageId": "xxxxx"
},
"payload": {payload}
}
}

The setting specific fields should be specified in a SettingEventMetadata passed as an argument on creation this object.

Parameters
payloadThe report payload. It should be a valid JSON element.
Returns
A future expressing if the event has been guaranteed to be sent to AVS.

Implemented in alexaClientSDK::capabilityAgents::doNotDisturb::DoNotDisturbCapabilityAgent, and alexaClientSDK::settings::SettingEventSender.


The documentation for this class was generated from the following file:

AlexaClientSDK 3.0.0 - Copyright 2016-2022 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the Apache License, Version 2.0