AlexaClientSDK  3.0.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
Static Public Member Functions | List of all members
alexaClientSDK::afml::VisualActivityTracker Class Reference

#include <VisualActivityTracker.h>

Inheritance diagram for alexaClientSDK::afml::VisualActivityTracker:
Inheritance graph
Collaboration diagram for alexaClientSDK::afml::VisualActivityTracker:
Collaboration graph

Public Member Functions

StateProviderInterface Functions
void provideState (const avsCommon::avs::NamespaceAndName &stateProviderName, unsigned int stateRequestToken) override
ActivityTrackerInterface Functions
void notifyOfActivityUpdates (const std::vector< Channel::State > &channelStates) override
CapabilityConfigurationInterface Functions
std::unordered_set< std::shared_ptr< avsCommon::avs::CapabilityConfiguration > > getCapabilityConfigurations () override
- 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
- Public Member Functions inherited from alexaClientSDK::afml::ActivityTrackerInterface
virtual ~ActivityTrackerInterface ()=default
 Destructor. More...
- Public Member Functions inherited from alexaClientSDK::avsCommon::sdkInterfaces::CapabilityConfigurationInterface
virtual ~CapabilityConfigurationInterface ()=default
- Public Member Functions inherited from alexaClientSDK::avsCommon::sdkInterfaces::StateProviderInterface
virtual ~StateProviderInterface ()=default
virtual void provideState (const avs::CapabilityTag &stateProviderName, const ContextRequestToken stateRequestToken)
virtual bool canStateBeRetrieved ()
virtual bool hasReportableStateProperties ()
virtual bool shouldQueryState ()

Static Public Member Functions

static acsdkManufactory::Annotated< avsCommon::sdkInterfaces::VisualFocusAnnotation, ActivityTrackerInterfacecreateVisualActivityTrackerInterface (std::shared_ptr< avsCommon::sdkInterfaces::ContextManagerInterface > contextManager, std::shared_ptr< acsdkShutdownManagerInterfaces::ShutdownNotifierInterface > shutdownNotifier, acsdkManufactory::Annotated< avsCommon::sdkInterfaces::endpoints::DefaultEndpointAnnotation, avsCommon::sdkInterfaces::endpoints::EndpointCapabilitiesRegistrarInterface > defaultEndpointCapabilitiesRegistrar)
static std::shared_ptr< VisualActivityTrackercreate (std::shared_ptr< avsCommon::sdkInterfaces::ContextManagerInterface > contextManager)

Additional Inherited Members

Detailed Description

The VisualActivityTracker implements the ActivityTrackerInterface and gets notification from the FocusManager any activities in the visual channels. It also implements the StateProviderInterface and will provide to AVS the activity of the visual channels as described in Focus Management.

Member Function Documentation

◆ create()

static std::shared_ptr<VisualActivityTracker> alexaClientSDK::afml::VisualActivityTracker::create ( std::shared_ptr< avsCommon::sdkInterfaces::ContextManagerInterface contextManager)

Creates a new VisualActivityTracker instance.

contextManagerThe AVS Context manager used to generate system context for events.
A std::shared_ptr to the new VisualActivityTracker instance, or nullptr if the operation failed.

◆ createVisualActivityTrackerInterface()

Creates a new ActivityTrackerInterface instance, annotated with VisualFocusAnnotation.

contextManagerThe AVS Context manager used to generate system context for events.
shutdownNotifierThe object to notify this instance when it is time to shut down.
defaultEndpointCapabilitiesRegistrarThe capabilities registrar for the default endpoint with which to register this capability.
An Annotated std::shared_ptr to the new AudioActivityTracker instance, or nullptr if the operation failed.

◆ getCapabilityConfigurations()

std::unordered_set<std::shared_ptr<avsCommon::avs::CapabilityConfiguration> > alexaClientSDK::afml::VisualActivityTracker::getCapabilityConfigurations ( )

Returns the configurations of the capability interfaces being implemented.

A set of CapabilityConfigurations

Implements alexaClientSDK::avsCommon::sdkInterfaces::CapabilityConfigurationInterface.

◆ notifyOfActivityUpdates()

void alexaClientSDK::afml::VisualActivityTracker::notifyOfActivityUpdates ( const std::vector< Channel::State > &  channelStates)

This function is called whenever an activity in FocusManager causes updates to a vector of channels.

channelStatesA vector of Channel::State that has been updated.

Implements alexaClientSDK::afml::ActivityTrackerInterface.

◆ provideState()

void alexaClientSDK::afml::VisualActivityTracker::provideState ( const avsCommon::avs::NamespaceAndName stateProviderName,
unsigned int  stateRequestToken 

A request to a StateProvider to provide the state. The StateProvider should perform minimum processing and return quickly, otherwise it will block the processing of updating the states of other StateProviders. The ContextManager specifies a token which it uses to track the getContext request associated with this provideState request. The stateProviderInterface must use the same token when it updates its state via the setState call.

: The setState method MUST be called from a different thread from where the provideState method is being called from.

stateProviderNameThe name of the state provider.
stateRequestTokenThe token to use in the setState call.
NamespaceAndName is being deprecated. Use the CapabilityMessageIdentifier version instead.

Reimplemented from alexaClientSDK::avsCommon::sdkInterfaces::StateProviderInterface.

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

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