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

#include <APLCapabilityAgentObserverInterface.h>

Inheritance diagram for alexaClientSDK::aplCapabilityCommonInterfaces::APLCapabilityAgentObserverInterface:
Inheritance graph
[legend]

Public Member Functions

virtual ~APLCapabilityAgentObserverInterface ()=default
 
virtual void onRenderDocument (const std::string &document, const std::string &datasource, const PresentationToken &token, const std::string &windowId, const APLTimeoutType timeoutType, const std::string &interfaceName, const std::string &supportedViewports, const PresentationSession &presentationSession, const std::chrono::steady_clock::time_point &receiveTime, std::shared_ptr< APLCapabilityAgentInterface > agent)=0
 
virtual void onExecuteCommands (const std::string &jsonPayload, const PresentationToken &token)=0
 
virtual void onDataSourceUpdate (const std::string &sourceType, const std::string &jsonPayload, const PresentationToken &token)=0
 
virtual void onShowDocument (const PresentationToken &token)=0
 

Detailed Description

This APLCapabilityAgentObserverInterface class is used to notify observers when APL directive is received.

Constructor & Destructor Documentation

◆ ~APLCapabilityAgentObserverInterface()

virtual alexaClientSDK::aplCapabilityCommonInterfaces::APLCapabilityAgentObserverInterface::~APLCapabilityAgentObserverInterface ( )
virtualdefault

Destructor

Member Function Documentation

◆ onDataSourceUpdate()

virtual void alexaClientSDK::aplCapabilityCommonInterfaces::APLCapabilityAgentObserverInterface::onDataSourceUpdate ( const std::string &  sourceType,
const std::string &  jsonPayload,
const PresentationToken token 
)
pure virtual

Used to notify observer when Alexa.Presentation.APL directives related to DataSource updates received.

Parameters
sourceTypeDataSource type.
jsonPayloadThe payload of the directive in structured JSON format.
tokenpresentation token used in renderdocument

Implemented in alexaClientSDK::sampleApplications::ipcServerSampleApp::APLRuntimePresentationAdapter.

◆ onExecuteCommands()

virtual void alexaClientSDK::aplCapabilityCommonInterfaces::APLCapabilityAgentObserverInterface::onExecuteCommands ( const std::string &  jsonPayload,
const PresentationToken token 
)
pure virtual

Used to notify observer when Alexa.Presentation.APL.ExecuteCommands directive has been received.

Parameters
jsonPayloadThe payload of the Alexa.Presentation.APL.ExecuteCommands directive in structured JSON format.
tokenpresentation token used in renderdocument

Implemented in alexaClientSDK::sampleApplications::ipcServerSampleApp::APLRuntimePresentationAdapter.

◆ onRenderDocument()

virtual void alexaClientSDK::aplCapabilityCommonInterfaces::APLCapabilityAgentObserverInterface::onRenderDocument ( const std::string &  document,
const std::string &  datasource,
const PresentationToken token,
const std::string &  windowId,
const APLTimeoutType  timeoutType,
const std::string &  interfaceName,
const std::string &  supportedViewports,
const PresentationSession presentationSession,
const std::chrono::steady_clock::time_point &  receiveTime,
std::shared_ptr< APLCapabilityAgentInterface agent 
)
pure virtual

Used to notify the observer when an APL document is ready to be rendered, typically in response to a Alexa.Presentation.APL.RenderDocument directive being received. Once called, the client should render the document based on the APL specification in the payload in structured JSON format.

Note
The payload may contain customer sensitive information and should be used with utmost care. Failure to do so may result in exposing or mishandling of customer data.
Parameters
documentJSON string containing APL document
datasourceJSON string containing data payload associated with APL document
tokenThe APL presentation token associated with this payload.
windowIdThe target windowId.
timeoutTypeThe APLTimeoutType associated with this payload.
interfaceNameThe interface (namespace) which is associated with this directive.
supportedViewportsstring containing the json value of supported viewports.
presentationSessionConfiguration for presentation session displaying document
receiveTimeThe time at which the directive was received, for more accurate telemetry.
agentPointer to the APLCapabilityAgentInterface notifying the observer.

◆ onShowDocument()

virtual void alexaClientSDK::aplCapabilityCommonInterfaces::APLCapabilityAgentObserverInterface::onShowDocument ( const PresentationToken token)
pure virtual

Used to notify observer when a show document directive has been received for an existing presentation.

Parameters
tokenpresentation token used in renderdocument

Implemented in alexaClientSDK::sampleApplications::ipcServerSampleApp::APLRuntimePresentationAdapter.


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