AlexaClientSDK  1.25.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
Public Types | Public Member Functions | List of all members
alexaClientSDK::avsCommon::sdkInterfaces::CapabilitiesDelegateObserverInterface Class Referenceabstract

#include <CapabilitiesDelegateObserverInterface.h>

Inheritance diagram for alexaClientSDK::avsCommon::sdkInterfaces::CapabilitiesDelegateObserverInterface:
Inheritance graph
[legend]

Public Types

enum  State { State::UNINITIALIZED, State::SUCCESS, State::FATAL_ERROR, State::RETRIABLE_ERROR }
 The enum State describes the state of the CapabilitiesDelegate. More...
 
enum  Error {
  Error::UNINITIALIZED, Error::SUCCESS, Error::UNKNOWN_ERROR, Error::CANCELED,
  Error::FORBIDDEN, Error::SERVER_INTERNAL_ERROR, Error::BAD_REQUEST
}
 The enum Error encodes possible errors which may occur when changing state. More...
 

Public Member Functions

virtual ~CapabilitiesDelegateObserverInterface ()=default
 
virtual void onCapabilitiesStateChange (State newState, Error newError, const std::vector< std::string > &addedOrUpdatedEndpointIds, const std::vector< std::string > &deletedEndpointIds)=0
 

Detailed Description

This interface is used to observe changes to the state of the CapabilitiesDelegate.

Member Enumeration Documentation

◆ Error

The enum Error encodes possible errors which may occur when changing state.

Enumerator
UNINITIALIZED 

The state (and hence the error) has not been initialized.

SUCCESS 

Success.

UNKNOWN_ERROR 

An unknown error occurred.

CANCELED 

The request was canceled.

FORBIDDEN 

The authorization failed.

SERVER_INTERNAL_ERROR 

The server encountered a runtime error.

BAD_REQUEST 

The request is missing a required parameter, has an invalid value, or is otherwise improperly formed.

◆ State

The enum State describes the state of the CapabilitiesDelegate.

Enumerator
UNINITIALIZED 

CapabilitiesDelegate is uninitialized.

SUCCESS 

The Capabilities API message went through without issues.

FATAL_ERROR 

The message did not go through because of issues that need fixing.

RETRIABLE_ERROR 

The message did not go through, but you can retry to see if you succeed.

Constructor & Destructor Documentation

◆ ~CapabilitiesDelegateObserverInterface()

virtual alexaClientSDK::avsCommon::sdkInterfaces::CapabilitiesDelegateObserverInterface::~CapabilitiesDelegateObserverInterface ( )
virtualdefault

Virtual destructor to assure proper cleanup of derived types.

Member Function Documentation

◆ onCapabilitiesStateChange()

virtual void alexaClientSDK::avsCommon::sdkInterfaces::CapabilitiesDelegateObserverInterface::onCapabilitiesStateChange ( State  newState,
Error  newError,
const std::vector< std::string > &  addedOrUpdatedEndpointIds,
const std::vector< std::string > &  deletedEndpointIds 
)
pure virtual

Notification that an CapabilitiesDelegate state has changed.

Note
Implementations of this method must not call CapabilitiesDelegate methods because the CapabilitiesDelegate may be in a 'locked' state at the time this call is made. If you do, then you may end up with a deadlock.
Parameters
newStateThe new state of the CapabilitiesDelegate.
newErrorThe error associated to the state change.
addedOrUpdatedEndpointIdsThe endpoint identifiers of endpoints sent in the addOrUpdateReport.
deletedEndpointIdsThe endpoint identifiers of endpoints sent in the deleteReport.

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

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