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

#include <ModeControllerAttributeBuilderInterface.h>

Inheritance diagram for alexaClientSDK::avsCommon::sdkInterfaces::modeController::ModeControllerAttributeBuilderInterface:
Inheritance graph
[legend]

Public Member Functions

virtual ~ModeControllerAttributeBuilderInterface ()=default
 
virtual ModeControllerAttributeBuilderInterfacewithCapabilityResources (const avsCommon::avs::CapabilityResources &capabilityResources)=0
 
virtual ModeControllerAttributeBuilderInterfaceaddMode (const std::string &mode, const ModeResources &modeResources)=0
 
virtual ModeControllerAttributeBuilderInterfacesetOrdered (bool ordered)=0
 
virtual ModeControllerAttributeBuilderInterfacewithSemantics (const avsCommon::avs::capabilitySemantics::CapabilitySemantics &semantics)=0
 
virtual utils::Optional< ModeControllerAttributesbuild ()=0
 

Detailed Description

Interface for a mode controller attribute builder.

The builder is responsible for building a ModeControllerAttributes object.

Note
The attribute builder will fail if following conditions are not met:
  • CapabilityResources with at least one friendly name.
  • At least one mode with mode resources that contains atleast one friendly name.

Constructor & Destructor Documentation

◆ ~ModeControllerAttributeBuilderInterface()

virtual alexaClientSDK::avsCommon::sdkInterfaces::modeController::ModeControllerAttributeBuilderInterface::~ModeControllerAttributeBuilderInterface ( )
virtualdefault

Destructor.

Member Function Documentation

◆ addMode()

virtual ModeControllerAttributeBuilderInterface& alexaClientSDK::avsCommon::sdkInterfaces::modeController::ModeControllerAttributeBuilderInterface::addMode ( const std::string &  mode,
const ModeResources modeResources 
)
pure virtual

Add a mode with mode name and its mode resources.

Note
By default modes added using this method are considered as not ordered. However, to enforce ordering of the modes as the way these are inserted into, call setOrdered with true.
Calling this with the same mode name shall overwrite the previous value.
Parameters
modeA mode of controller.
modeResourcesThe mode resources represeneted using ModeResources.
Returns
This builder which can be used to nest configuration function calls.

Implemented in alexaClientSDK::capabilityAgents::modeController::ModeControllerAttributeBuilder.

◆ build()

virtual utils::Optional<ModeControllerAttributes> alexaClientSDK::avsCommon::sdkInterfaces::modeController::ModeControllerAttributeBuilderInterface::build ( )
pure virtual

Builds a ModeControllerAttributes with the configured properties.

Returns
A non optional ModeControllerAttributes if the build succeeds; otherwise, an empty ModeControllerAttributes object.

Implemented in alexaClientSDK::capabilityAgents::modeController::ModeControllerAttributeBuilder.

◆ setOrdered()

virtual ModeControllerAttributeBuilderInterface& alexaClientSDK::avsCommon::sdkInterfaces::modeController::ModeControllerAttributeBuilderInterface::setOrdered ( bool  ordered)
pure virtual

Configures builders about the order of the modes in the controller.

Note
The order here means how the modes are organized in the mode controller. By setting this to true, you enable the Alexa to send the adjustMode directive.
See also
https://developer.amazon.com/docs/alexa/alexa-voice-service/alexa-modecontroller.html#capability-assertion
Note
Calling this again will overrite the previous provided value.
Parameters
orderedThe ordering of the modes in the controller.
Returns
This builder which can be used to nest configuration function calls.

Implemented in alexaClientSDK::capabilityAgents::modeController::ModeControllerAttributeBuilder.

◆ withCapabilityResources()

virtual ModeControllerAttributeBuilderInterface& alexaClientSDK::avsCommon::sdkInterfaces::modeController::ModeControllerAttributeBuilderInterface::withCapabilityResources ( const avsCommon::avs::CapabilityResources capabilityResources)
pure virtual

Configures builder to use capability resources.

Note
This will overwrite capability resources if it was used previously.
Parameters
capabilityResourcesThe capability resources represented using CapabilityResources.
Returns
This builder which can be used to nest configuration function calls.

Implemented in alexaClientSDK::capabilityAgents::modeController::ModeControllerAttributeBuilder.

◆ withSemantics()

virtual ModeControllerAttributeBuilderInterface& alexaClientSDK::avsCommon::sdkInterfaces::modeController::ModeControllerAttributeBuilderInterface::withSemantics ( const avsCommon::avs::capabilitySemantics::CapabilitySemantics semantics)
pure virtual

Configures the builder to use the specified semantics definition.

See also
https://developer.amazon.com/docs/alexa/alexa-voice-service/alexa-modecontroller.html
Parameters
semanticsThe CapabilitySemantics representing the semantics definition.
Returns
This builder, which can be used to nest configuration function calls.

Implemented in alexaClientSDK::capabilityAgents::modeController::ModeControllerAttributeBuilder.


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