![]() |
AlexaClientSDK
1.19.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
|
Namespaces | |
test | |
Classes | |
class | BasicDeviceConnectionRule |
class | Bluetooth |
class | BluetoothEventState |
class | BluetoothMediaInputTransformer |
class | BluetoothStorageInterface |
A storage interface used for Bluetooth that should provide UUID to MAC mappings and maintain insertion order. More... | |
class | SQLiteBluetoothStorage |
A concrete implementation of BluetoothStorageInterface using SQLite. More... | |
Typedefs | |
using | MediaPlayerState = avsCommon::utils::mediaPlayer::MediaPlayerState |
Functions | |
std::string | streamingStateToString (Bluetooth::StreamingState state) |
std::ostream & | operator<< (std::ostream &stream, const Bluetooth::StreamingState state) |
std::string | focusTransitionStateToString (Bluetooth::FocusTransitionState state) |
std::ostream & | operator<< (std::ostream &stream, const Bluetooth::FocusTransitionState state) |
std::string | scanningStateToString (Bluetooth::ScanningTransitionState state) |
std::ostream & | operator<< (std::ostream &stream, const Bluetooth::ScanningTransitionState state) |
static std::shared_ptr< avsCommon::avs::CapabilityConfiguration > | getBluetoothCapabilityConfiguration () |
static std::string | truncateWithDefault (const std::string &mac, const std::string &defaultString="XX:XX:XX:XX:XX:XX") |
static std::string | truncateFriendlyName (const std::string &friendlyName) |
static bool | supportsAvsProfile (std::shared_ptr< BluetoothDeviceInterface > device, const std::string &avsProfileName) |
static bool | waitOnFuture (std::future< bool > future, std::string description="", std::chrono::milliseconds timeout=DEFAULT_FUTURE_TIMEOUT) |
static std::string | convertToAVSStreamingState (const Bluetooth::StreamingState &state) |
static bool | validateDeviceConnectionRules (std::unordered_set< std::shared_ptr< avsCommon::sdkInterfaces::bluetooth::BluetoothDeviceConnectionRuleInterface >> enabledConnectionRules) |
static std::string | convertToAVSConnectedState (const DeviceState &state) |
static bool | parseDirectivePayload (const std::string &payload, Document *document) |
Variables | |
static const std::string | TAG {"Bluetooth"} |
String to identify log entries originating from this file. More... | |
static const std::string | NAMESPACE = "Bluetooth" |
The Bluetooth interface namespace. More... | |
static const NamespaceAndName | BLUETOOTH_STATE {NAMESPACE, "BluetoothState"} |
The Bluetooth state portion of the Context. More... | |
static const NamespaceAndName | SCAN_DEVICES {NAMESPACE, "ScanDevices"} |
The ScanDevices directive identifier. More... | |
static const NamespaceAndName | SCAN_DEVICES_REPORT {NAMESPACE, "ScanDevicesReport"} |
The ScanDevicesReport event. More... | |
static const NamespaceAndName | SCAN_DEVICES_FAILED {NAMESPACE, "ScanDevicesFailed"} |
The ScanDevicesFailed event. More... | |
static const NamespaceAndName | ENTER_DISCOVERABLE_MODE {NAMESPACE, "EnterDiscoverableMode"} |
The EnterDiscoverableMode directive identifier. More... | |
static const NamespaceAndName | ENTER_DISCOVERABLE_MODE_SUCCEEDED {NAMESPACE, "EnterDiscoverableModeSucceeded"} |
The EnterDiscoverableModeSucceeded event. More... | |
static const NamespaceAndName | ENTER_DISCOVERABLE_MODE_FAILED {NAMESPACE, "EnterDiscoverableModeFailed"} |
The EnterDiscoverableModeFailed event. More... | |
static const NamespaceAndName | EXIT_DISCOVERABLE_MODE {NAMESPACE, "ExitDiscoverableMode"} |
The ExitDiscoverableMode directive identifier. More... | |
static const NamespaceAndName | PAIR_DEVICES_SUCCEEDED {NAMESPACE, "PairDevicesSucceeded"} |
The PairDevicesSucceeded event. More... | |
static const NamespaceAndName | PAIR_DEVICES_FAILED {NAMESPACE, "PairDevicesFailed"} |
The PairDevicesFailed event. More... | |
static const NamespaceAndName | PAIR_DEVICES {NAMESPACE, "PairDevices"} |
The PairDevices directive identifier. More... | |
static const NamespaceAndName | UNPAIR_DEVICES {NAMESPACE, "UnpairDevices"} |
The UnpairDevices directive identifier. More... | |
static const NamespaceAndName | UNPAIR_DEVICES_SUCCEEDED {NAMESPACE, "UnpairDevicesSucceeded"} |
The UnpairDevicesSucceeded event. More... | |
static const NamespaceAndName | UNPAIR_DEVICES_FAILED {NAMESPACE, "UnpairDevicesFailed"} |
The UnpairDevicesFailed event. More... | |
static const NamespaceAndName | SET_DEVICE_CATEGORIES {NAMESPACE, "SetDeviceCategories"} |
The SetDeviceCategories directive identifier. More... | |
static const NamespaceAndName | SET_DEVICE_CATEGORIES_SUCCEEDED {NAMESPACE, "SetDeviceCategoriesSucceeded"} |
The SetDeviceCategoriesSucceeded event. More... | |
static const NamespaceAndName | SET_DEVICE_CATEGORIES_FAILED {NAMESPACE, "SetDeviceCategoriesFailed"} |
The SetDeviceCategoriesFailed event. More... | |
static const NamespaceAndName | CONNECT_BY_DEVICE_IDS {NAMESPACE, "ConnectByDeviceIds"} |
The ConnectByDeviceIds directive identifier. More... | |
static const NamespaceAndName | CONNECT_BY_DEVICE_IDS_SUCCEEDED {NAMESPACE, "ConnectByDeviceIdsSucceeded"} |
The ConnectByDeviceIdsSucceeded event. More... | |
static const NamespaceAndName | CONNECT_BY_DEVICE_IDS_FAILED {NAMESPACE, "ConnectByDeviceIdsFailed"} |
The ConnectByDeviceIdsFailed event. More... | |
static const NamespaceAndName | CONNECT_BY_PROFILE {NAMESPACE, "ConnectByProfile"} |
The ConnectByProfile directive identifier. More... | |
static const NamespaceAndName | CONNECT_BY_PROFILE_SUCCEEDED {NAMESPACE, "ConnectByProfileSucceeded"} |
The ConnectByProfileSucceeded event. More... | |
static const NamespaceAndName | CONNECT_BY_PROFILE_FAILED {NAMESPACE, "ConnectByProfileFailed"} |
The ConnectByProfileFailed event. More... | |
static const NamespaceAndName | DISCONNECT_DEVICES {NAMESPACE, "DisconnectDevices"} |
The DisconnectDevices directive identifier. More... | |
static const NamespaceAndName | DISCONNECT_DEVICES_SUCCEEDED {NAMESPACE, "DisconnectDevicesSucceeded"} |
The DisconnectDevicesSucceeded event. More... | |
static const NamespaceAndName | DISCONNECT_DEVICES_FAILED {NAMESPACE, "DisconnectDevicesFailed"} |
The DisconnectDevicesFailed event. More... | |
static const NamespaceAndName | PLAY {NAMESPACE, "Play"} |
The Play directive identifier. More... | |
static const NamespaceAndName | MEDIA_CONTROL_PLAY_SUCCEEDED {NAMESPACE, "MediaControlPlaySucceeded"} |
The MediaControlPlaySucceeded event. More... | |
static const NamespaceAndName | MEDIA_CONTROL_PLAY_FAILED {NAMESPACE, "MediaControlPlayFailed"} |
The MediaControlPlayFailed event. More... | |
static const NamespaceAndName | STOP {NAMESPACE, "Stop"} |
The Stop directive identifier. More... | |
static const NamespaceAndName | MEDIA_CONTROL_STOP_SUCCEEDED {NAMESPACE, "MediaControlStopSucceeded"} |
The MediaControlStopSucceeded event. More... | |
static const NamespaceAndName | MEDIA_CONTROL_STOP_FAILED {NAMESPACE, "MediaControlStopFailed"} |
The MediaControlStopFailed event. More... | |
static const NamespaceAndName | NEXT {NAMESPACE, "Next"} |
The Next directive identifier. More... | |
static const NamespaceAndName | MEDIA_CONTROL_NEXT_SUCCEEDED {NAMESPACE, "MediaControlNextSucceeded"} |
The MediaControlNextSucceeded event. More... | |
static const NamespaceAndName | MEDIA_CONTROL_NEXT_FAILED {NAMESPACE, "MediaControlNextFailed"} |
The MediaControlNextFailed event. More... | |
static const NamespaceAndName | PREVIOUS {NAMESPACE, "Previous"} |
The Previous directive identifier. More... | |
static const NamespaceAndName | MEDIA_CONTROL_PREVIOUS_SUCCEEDED {NAMESPACE, "MediaControlPreviousSucceeded"} |
The MediaControlPreviousSucceeded event. More... | |
static const NamespaceAndName | MEDIA_CONTROL_PREVIOUS_FAILED {NAMESPACE, "MediaControlPreviousFailed"} |
The MediaControlPreviousFailed event. More... | |
static const NamespaceAndName | STREAMING_STARTED {NAMESPACE, "StreamingStarted"} |
The StreamingStarted event. More... | |
static const NamespaceAndName | STREAMING_ENDED {NAMESPACE, "StreamingEnded"} |
The StreamingEnded event. More... | |
static const std::string | CHANNEL_NAME = FocusManagerInterface::CONTENT_CHANNEL_NAME |
The Channel name. More... | |
static const std::string | ACTIVITY_ID = "Bluetooth" |
Activity ID for use by FocusManager. More... | |
static const unsigned int | MAX_CONNECT_BY_PROFILE_COUNT = 2 |
Max number of paired devices connect by profile should atempt connect to. More... | |
static const std::chrono::milliseconds | CMD_DELAY {100} |
A delay to deal with devices that can't process consecutive AVRCP commands. More... | |
static const std::chrono::milliseconds | INITIALIZE_SOURCE_DELAY {1000} |
static const std::chrono::seconds | DEFAULT_FUTURE_TIMEOUT {45} |
static const std::chrono::minutes | TRANSIENT_FOCUS_DURATION {2} |
static const char | ALEXA_DEVICE_NAME_KEY [] = "alexaDevice" |
A key for the alexa (host) device. More... | |
static const char | DEVICE_KEY [] = "device" |
A key for a device. More... | |
static const char | DEVICES_KEY [] = "devices" |
A key for a devices. More... | |
static const char | DISCOVERED_DEVICES_KEY [] = "discoveredDevices" |
A key for discovered devices. More... | |
static const char | HAS_MORE_KEY [] = "hasMore" |
A key to indicate if more devices are to be reported. More... | |
static const std::string | EMPTY_PAYLOAD = "{}" |
An empty payload. More... | |
static const char | FRIENDLY_NAME_KEY [] = "friendlyName" |
The friendly name. More... | |
static const char | NAME_KEY [] = "name" |
The name key for a profile. More... | |
static const char | VERSION_KEY [] = "version" |
The version key for a profile. More... | |
static const char | PAIRED_DEVICES_KEY [] = "pairedDevices" |
Identifying paired devices. More... | |
static const char | PROFILE_KEY [] = "profile" |
Identifying a profile. More... | |
static const char | PROFILES_KEY [] = "profiles" |
Identifying an array of profiles. More... | |
static const char | PROFILE_NAME_KEY [] = "profileName" |
Identifying a profile name. More... | |
static const char | REQUESTER_KEY [] = "requester" |
Identifying the requester of the operation. More... | |
static const char | STREAMING_KEY [] = "streaming" |
A key indicating streaming status. More... | |
static const char | STATE_KEY [] = "state" |
A key indicating state. More... | |
static const char | SUPPORTED_PROFILES_KEY [] = "supportedProfiles" |
Indicates the supported profiles. More... | |
static const char | TRUNCATED_MAC_ADDRESS_KEY [] = "truncatedMacAddress" |
The truncated mac address. More... | |
static const char | UNIQUE_DEVICE_ID_KEY [] = "uniqueDeviceId" |
The uuid generated to identify a device. More... | |
static const char | METADATA_KEY [] = "metadata" |
The metadata. More... | |
static const char | VENDOR_ID_KEY [] = "vendorId" |
The Vendor Id. More... | |
static const char | PRODUCT_ID_KEY [] = "productId" |
The Product Id. More... | |
static const char | CLASS_OF_DEVICE_KEY [] = "classOfDevice" |
The Class of Device. More... | |
static const char | VENDOR_DEVICE_SIG_ID_KEY [] = "vendorDeviceSigId" |
The Vendor Device SigID. More... | |
static const char | VENDOR_DEVICE_ID_KEY [] = "vendorDeviceId" |
The Vendor Device ID. More... | |
static const char | DEVICE_CATEGORY_KEY [] = "deviceCategory" |
Identifying a device category. More... | |
static const char | CONNECTION_STATE_KEY [] = "connectionState" |
Identifying the connection status of a device. More... | |
static const std::string | AVS_A2DP_SOURCE = "A2DP-SOURCE" |
A2DP Source. More... | |
static const std::string | AVS_A2DP_SINK = "A2DP-SINK" |
A2DP Sink. More... | |
static const std::string | AVS_A2DP = "A2DP" |
General A2DP. More... | |
static const std::string | AVS_AVRCP = "AVRCP" |
static const std::string | AVS_HFP = "HFP" |
HFP. More... | |
static const std::string | AVS_HID = "HID" |
HID. More... | |
static const std::string | AVS_SPP = "SPP" |
SPP. More... | |
static const std::map< std::string, std::string > | AVS_PROFILE_MAP |
A mapping of Bluetooth service UUIDs to AVS profile identifiers. More... | |
static const std::map< DeviceCategory, std::unordered_set< std::string > > | DEVICECATEGORY_PROFILES_MAP |
static const std::string | BLUETOOTH_CAPABILITY_INTERFACE_TYPE = "AlexaInterface" |
static const std::string | BLUETOOTH_CAPABILITY_INTERFACE_NAME = "Bluetooth" |
Bluetooth interface name. More... | |
static const std::string | BLUETOOTH_CAPABILITY_INTERFACE_VERSION = "2.0" |
Bluetooth interface version. Version 1.0 works with StreamingStarted and StreamingEnded. More... | |
static const std::string | BLUETOOTH_CAPABILITY_CONFIGURATION_VALUE |
Bluetooth configurations value. More... | |
static const std::string | TAG {"BluetoothMediaInputTransformer"} |
String to identify log entries originating from this file. More... | |
static const std::string | BLUETOOTH_CONFIGURATION_ROOT_KEY = "bluetooth" |
Configuration root. More... | |
static const std::string | BLUETOOTH_DB_FILE_PATH_KEY = "databaseFilePath" |
The node identifying the database. More... | |
static const std::string | UUID_TABLE_NAME = "uuidMapping" |
Table name. More... | |
static const std::string | COLUMN_UUID = "uuid" |
The UUID column. More... | |
static const std::string | COLUMN_MAC = "mac" |
The MAC address column. More... | |
static const std::string | COLUMN_CATEGORY = "category" |
The Category column. More... | |
using alexaClientSDK::capabilityAgents::bluetooth::MediaPlayerState = typedef avsCommon::utils::mediaPlayer::MediaPlayerState |
|
static |
Utility function to squash DeviceState
into the connection state that AVS has defined.
state | The DeviceState |
|
static |
Utility function to squash StreamingState
into the streaming states that AVS has defined.
state | The StreamingState . |
|
inline |
Converts an enum FocusTransitionState
to a string.
state | The FocusTransitionState . |
|
static |
|
inline |
Overload for the StreamingState
enum. This will write the StreamingState
as a string to the provided stream.
stream | An ostream to send the StreamingState as a string. |
state | The StreamingState to convert. |
|
inline |
Overload for the FocusTransitionState
enum. This will write the FocusTransitionState
as a string to the provided stream.
stream | An ostream to send the FocusTransitionState as a string. |
state | The FocusTransitionState to convert. |
|
inline |
Overload for the ScanningTransitionState
enum. This will write the ScanningTransitionState
as a string to the provided stream.
stream | An ostream to send the ScanningTransitionState as a string. |
state | The ScanningTransitionState to convert. |
|
static |
|
inline |
Converts an enum ScanningTransitionState
to a string.
state | The ScanningTransitionState . |
|
inline |
Converts an enum to a string.
state | The StreamingState . |
|
static |
Utility function to evaluate whether a device supports a specific AVS profile.
device | The device. |
avsProfileName | The AVS Profile to match against. |
A | bool indicating whether the device supports the specific profile. |
|
static |
|
static |
Utility function to truncate a MAC address.
mac | The mac address. |
defaultString | The default truncated mac address to return if the mac address is invalid. |
|
static |
Utility function to evaluate whether connection rules are valid. Device categories defined in the BasicDeviceConnectionRule
are enabled by the Bluetoooth CapabilityAgent by default and are not allowed to be overwritten.
enabledConnectionRules | a set of device connection rules defined by customers. |
|
static |
Wait for a a future function to be resolved.
future | The future |
description | The desription of the future function. |
timeout | The timeout given to the future. |
|
static |
Activity ID for use by FocusManager.
|
static |
A key for the alexa (host) device.
|
static |
General A2DP.
|
static |
A2DP Sink.
|
static |
A2DP Source.
|
static |
AVS identifies this as just AVRCP. It technically refers to AVRCPTarget, since the presence of this profile will dictate whether AVS will send down Media control directives.
|
static |
HFP.
|
static |
HID.
|
static |
A mapping of Bluetooth service UUIDs to AVS profile identifiers.
|
static |
SPP.
|
static |
Bluetooth configurations value.
|
static |
Bluetooth interface name.
|
static |
|
static |
Bluetooth interface version. Version 1.0 works with StreamingStarted and StreamingEnded.
|
static |
Configuration root.
|
static |
The node identifying the database.
|
static |
The Bluetooth state portion of the Context.
|
static |
The Channel
name.
|
static |
The Class of Device.
|
static |
A delay to deal with devices that can't process consecutive AVRCP commands.
|
static |
The Category column.
|
static |
The MAC address column.
|
static |
The UUID column.
|
static |
The ConnectByDeviceIds
directive identifier.
|
static |
The ConnectByDeviceIdsFailed
event.
|
static |
The ConnectByDeviceIdsSucceeded
event.
|
static |
The ConnectByProfile
directive identifier.
|
static |
The ConnectByProfileFailed
event.
|
static |
The ConnectByProfileSucceeded
event.
|
static |
Identifying the connection status of a device.
|
static |
The maximum about of time to block on a future from the Bluetooth implementation before it should be rejected.
|
static |
Identifying a device category.
|
static |
A key for a device.
|
static |
A mapping of DeviceCategory to its dependent service UUIDs. List all necessary profiles needed for a device with the following DeviceCategory: 1)DeviceCategory::REMOTE_CONTROL 2)DeviceCategory::GADGET All other categories are already enforced to have correct dependent profiles by BasicDeviceConnectionRule
.
|
static |
A key for a devices.
|
static |
The DisconnectDevices
directive identifier.
|
static |
The DisconnectDevicesFailed
event.
|
static |
The DisconnectDevicesSucceeded
event.
|
static |
A key for discovered devices.
|
static |
An empty payload.
|
static |
The EnterDiscoverableMode
directive identifier.
|
static |
The EnterDiscoverableModeFailed
event.
|
static |
The EnterDiscoverableModeSucceeded
event.
|
static |
The ExitDiscoverableMode
directive identifier.
|
static |
The friendly name.
|
static |
A key to indicate if more devices are to be reported.
|
static |
We get the stream faster than a peer device can process an AVRCP command (for example NEXT/PAUSE). Wait a bit before we get the stream so we don't get any buffers from before the command was processed.
|
static |
Max number of paired devices connect by profile should atempt connect to.
|
static |
The MediaControlNextFailed
event.
|
static |
The MediaControlNextSucceeded
event.
|
static |
The MediaControlPlayFailed
event.
|
static |
The MediaControlPlaySucceeded
event.
|
static |
The MediaControlPreviousFailed
event.
|
static |
The MediaControlPreviousSucceeded
event.
|
static |
The MediaControlStopFailed
event.
|
static |
The MediaControlStopSucceeded
event.
|
static |
The metadata.
|
static |
The name key for a profile.
|
static |
The Bluetooth interface namespace.
|
static |
The Next
directive identifier.
|
static |
The PairDevices
directive identifier.
|
static |
The PairDevicesFailed
event.
|
static |
The PairDevicesSucceeded
event.
|
static |
Identifying paired devices.
|
static |
The Play
directive identifier.
|
static |
The Previous
directive identifier.
|
static |
The Product Id.
|
static |
Identifying a profile.
|
static |
Identifying a profile name.
|
static |
Identifying an array of profiles.
|
static |
Identifying the requester of the operation.
|
static |
The ScanDevices
directive identifier.
|
static |
The ScanDevicesFailed
event.
|
static |
The ScanDevicesReport
event.
|
static |
The SetDeviceCategories
directive identifier.
|
static |
The SetDeviceCategoriesFailed
event.
|
static |
The SetDeviceCategoriesSucceeded
event.
|
static |
A key indicating state.
|
static |
The Stop
directive identifier.
|
static |
The StreamingEnded
event.
|
static |
A key indicating streaming status.
|
static |
The StreamingStarted
event.
|
static |
Indicates the supported profiles.
|
static |
String to identify log entries originating from this file.
|
static |
String to identify log entries originating from this file.
|
static |
The amount of time that the Bluetooth CA can hold onto the foreground channel and keep another CA in the background. If the time that the Bluetooth CA is in the foreground exceeds this value then other CAs will completely lose focus. If the Bluetooth CA loses focus within that time frame then the other CA which had focus will regain it and resume normal operation.
|
static |
The truncated mac address.
|
static |
The uuid generated to identify a device.
|
static |
The UnpairDevices
directive identifier.
|
static |
The UnpairDevicesFailed
event.
|
static |
The UnpairDevicesSucceeded
event.
|
static |
Table name.
|
static |
The Vendor Device ID.
|
static |
The Vendor Device SigID.
|
static |
The Vendor Id.
|
static |
The version key for a profile.
AlexaClientSDK 1.19.0 - Copyright 2016-2020 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the Apache License, Version 2.0