AlexaClientSDK
1.26.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
|
#include <PeripheralEndpointModeControllerHandler.h>
Static Public Member Functions | |
static std::shared_ptr< PeripheralEndpointModeControllerHandler > | create (const std::string &endpointName, const std::string &instance) |
Static Public Attributes | |
static const std::string | MODE_CONTROLLER_MODE_RED = "Red" |
The mode 'Red' of the controller. More... | |
static const std::string | MODE_CONTROLLER_MODE_GREEN = "Green" |
The mode 'Green' of the controller. More... | |
static const std::string | MODE_CONTROLLER_MODE_BLUE = "Blue" |
The mode 'Blue' of the controller. More... | |
Additional Inherited Members | |
Public Types inherited from alexaClientSDK::avsCommon::sdkInterfaces::modeController::ModeControllerInterface | |
using | ModeState = avsCommon::sdkInterfaces::modeController::ModeControllerObserverInterface::ModeState |
Alias to improve readability. More... | |
using | ModeControllerConfiguration = std::vector< std::string > |
An implementation of an ModeControllerInterface
.
|
override |
|
overridevirtual |
Adjust the mode of an instance.
modeDelta | The delta by which the controller mode should be changed (only applicable if the mode controller is ordered). |
cause | The appropriate AlexaStateChangeCauseType for this change. |
AlexaResponseType
and string. For the successful operation, the controller should return a pair of AlexaResponseType::SUCCESS
with an empty string, otherwise it returns pair with the appropriate reason from AlexaResponseType
and a description of the error. Implements alexaClientSDK::avsCommon::sdkInterfaces::modeController::ModeControllerInterface.
|
static |
Create a PeripheralEndpointModeControllerHandler object.
endpointName | The name of the endpoint. |
instance | The instance name of the capability. |
PeripheralEndpointModeControllerHandler
object if it succeeds; otherwise, nullptr
.
|
overridevirtual |
Gets the controller configuration as defined ModeControllerConfiguration
ModeControllerConfiguration
Implements alexaClientSDK::avsCommon::sdkInterfaces::modeController::ModeControllerInterface.
|
overridevirtual |
Gets the current mode of the instance.
AlexaResponseType::SUCCESS
and ModeState
otherwise returns a pair with the appropriate reason from AlexaResponseType
and an empty ModeState
. Implements alexaClientSDK::avsCommon::sdkInterfaces::modeController::ModeControllerInterface.
|
override |
void alexaClientSDK::sampleApp::PeripheralEndpointModeControllerHandler::setMode | ( | const std::string & | mode | ) |
Set the mode the controller.
mode | Mode of the controller. |
|
overridevirtual |
Set the mode of the instance.
mode | The desired mode of the instance. |
cause | The cause type for this action represented using AlexaStateChangeCauseType . |
AlexaResponseType
and string. For the successful operation, the controller should return a pair with AlexaResponseType::SUCCESS
with an empty string, otherwise returns a pair with the appropriate reason from AlexaResponseType
and a description of the error. Implements alexaClientSDK::avsCommon::sdkInterfaces::modeController::ModeControllerInterface.
|
static |
The mode 'Blue' of the controller.
|
static |
The mode 'Green' of the controller.
|
static |
The mode 'Red' of the controller.
AlexaClientSDK 1.26.0 - Copyright 2016-2022 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the Apache License, Version 2.0