AlexaClientSDK
3.0.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
|
#include <SystemHandler.h>
Public Member Functions | |
void | completeAuthorization (const std::string &url, const std::string &code, const std::string &clientId) |
void | setAlexaState (const std::string &state) |
void | setAuthorizationState (const std::string &state) |
void | setLocales (const std::string &localeStr) |
void | registerHandlers () |
Register this handler for its namespace and its methods for the corresponding namespace functions. More... | |
RequiresShutdown Functions | |
void | doShutdown () override |
Public Member Functions inherited from alexaClientSDK::sampleApplications::ipcServerSampleApp::ipc::IPCHandlerBase | |
void | invokeMethod (const std::string &methodName, const std::string &message) |
~IPCHandlerBase () | |
Public Member Functions inherited from alexaClientSDK::avsCommon::utils::RequiresShutdown | |
RequiresShutdown (const std::string &name) | |
virtual | ~RequiresShutdown () |
Destructor. More... | |
const std::string & | name () const |
void | shutdown () |
bool | isShutdown () const |
Static Public Member Functions | |
static std::shared_ptr< SystemHandler > | create (std::shared_ptr< IPCHandlerRegistrationInterface > ipcHandlerRegistrar, std::shared_ptr< SystemHandlerInterface > systemComponent) |
Additional Inherited Members | |
Public Types inherited from alexaClientSDK::sampleApplications::ipcServerSampleApp::ipc::IPCHandlerBase | |
using | IPCMessageHandler = std::function< void(const std::string &)> |
Alias for the message handler function. More... | |
Protected Member Functions inherited from alexaClientSDK::sampleApplications::ipcServerSampleApp::ipc::IPCHandlerBase | |
IPCHandlerBase (const std::string &namespaceName, std::shared_ptr< alexaClientSDK::avsCommon::utils::threading::Executor > executor) | |
bool | registerIPCMessageHandlerMethod (const std::string &methodName, IPCMessageHandler handlerFunction) |
bool | deregisterIPCMessageHandlerMethod (const std::string &methodName) |
Protected Attributes inherited from alexaClientSDK::sampleApplications::ipcServerSampleApp::ipc::IPCHandlerBase | |
std::string | m_namespaceName |
Name of the namespace of the realized IPC handler class. More... | |
std::unordered_map< std::string, IPCMessageHandler > | m_messageHandlers |
Dictionary to hold the IPC message handler methods. More... | |
std::shared_ptr< alexaClientSDK::avsCommon::utils::threading::Executor > | m_executor |
Executor context to support operations asynchronously. More... | |
A contract for the handler that will handle the System namespace messages coming from the IPC client.
void alexaClientSDK::sampleApplications::ipcServerSampleApp::ipc::SystemHandler::completeAuthorization | ( | const std::string & | url, |
const std::string & | code, | ||
const std::string & | clientId | ||
) |
Provides the IPC Client with information to complete CBL based authorization.
url | The url to use to complete CBL-based LWA authrorization. |
code | The CBL code to use to complete authorization. |
clientId | AVS Device Id. |
|
static |
Create an instance of SystemHandler
ipcHandlerRegistrar | Used to register SystemHandler . |
systemComponent | Handles the parsed System payloads. |
SystemHandler
|
overridevirtual |
Prepares/enables this object to be deleted. This should be the last function called on this object prior to deleting (or resetting) its shared_ptr.
Implements alexaClientSDK::avsCommon::utils::RequiresShutdown.
void alexaClientSDK::sampleApplications::ipcServerSampleApp::ipc::SystemHandler::registerHandlers | ( | ) |
Register this handler for its namespace and its methods for the corresponding namespace functions.
void alexaClientSDK::sampleApplications::ipcServerSampleApp::ipc::SystemHandler::setAlexaState | ( | const std::string & | state | ) |
Informs the IPC Client of changes in the state of the Alexa client connection.
state | Enumerated state of the Alexa client. |
void alexaClientSDK::sampleApplications::ipcServerSampleApp::ipc::SystemHandler::setAuthorizationState | ( | const std::string & | state | ) |
Informs the IPC Client of changes in Alexa Authorization status.
state | Enumerated authorization state. |
void alexaClientSDK::sampleApplications::ipcServerSampleApp::ipc::SystemHandler::setLocales | ( | const std::string & | localeStr | ) |
Informs the IPC Client of changes in supported locales for the SDK.
localeStr | The locale(s) for the device. In single-locale mode, contains one locale string. In multi-locale mode, the first string indicates the primary locale, and any other strings correspond to secondary locales. |
AlexaClientSDK 3.0.0 - Copyright 2016-2022 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the Apache License, Version 2.0