AlexaClientSDK  1.26.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
ExternalMediaPlayerCommon.h
Go to the documentation of this file.
1 /*
2  * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License").
5  * You may not use this file except in compliance with the License.
6  * A copy of the License is located at
7  *
8  * http://aws.amazon.com/apache2.0/
9  *
10  * or in the "license" file accompanying this file. This file is distributed
11  * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12  * express or implied. See the License for the specific language governing
13  * permissions and limitations under the License.
14  */
15 
16 #ifndef ACSDKEXTERNALMEDIAPLAYERINTERFACES_EXTERNALMEDIAPLAYERCOMMON_H_
17 #define ACSDKEXTERNALMEDIAPLAYERINTERFACES_EXTERNALMEDIAPLAYERCOMMON_H_
18 
19 namespace alexaClientSDK {
20 namespace acsdkExternalMediaPlayerInterfaces {
21 
23 enum class ValidationMethod {
29  NONE
30 };
31 
33 inline std::string validationMethodToString(ValidationMethod value) {
34  switch (value) {
36  return "SIGNING_CERTIFICATE";
38  return "GENERATED_CERTIFICATE";
40  return "NONE";
41  }
42  return "UNKNOWN";
43 }
44 
50  std::string localPlayerId;
51 
53  std::string spiVersion;
54 };
55 
62 
69  std::vector<std::string> validationData;
70 };
71 
75 struct PlayerInfo : public PlayerInfoBase {
82  PlayerInfo(const std::string& localPlayerId = "", const std::string& spiVersion = "", bool supported = false) :
84  playerSupported(supported) {
85  }
86 
88  std::string playerId;
89 
91  std::string skillToken;
92 
94  std::string playbackSessionId;
95 
99 };
100 
101 } // namespace acsdkExternalMediaPlayerInterfaces
102 } // namespace alexaClientSDK
103 
104 #endif // ACSDKEXTERNALMEDIAPLAYERINTERFACES_EXTERNALMEDIAPLAYERCOMMON_H_
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::PlayerInfoBase
Definition: ExternalMediaPlayerCommon.h:48
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::DiscoveredPlayerInfo::validationData
std::vector< std::string > validationData
Definition: ExternalMediaPlayerCommon.h:69
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::PlayerInfo::playerId
std::string playerId
The cloud provided playerID.
Definition: ExternalMediaPlayerCommon.h:88
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::ValidationMethod::GENERATED_CERTIFICATE
@ GENERATED_CERTIFICATE
Use a generated certificate.
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::PlayerInfo::playbackSessionId
std::string playbackSessionId
A universally unique identifier (UUID) generated to the RFC 4122 specification.
Definition: ExternalMediaPlayerCommon.h:94
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::ValidationMethod::SIGNING_CERTIFICATE
@ SIGNING_CERTIFICATE
Use a signing certificate for validation.
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::PlayerInfo
Definition: ExternalMediaPlayerCommon.h:75
alexaClientSDK
Whether or not curl logs should be emitted.
Definition: AVSConnectionManager.h:36
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::DiscoveredPlayerInfo::validationMethod
ValidationMethod validationMethod
The validation method used for this player.
Definition: ExternalMediaPlayerCommon.h:61
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::ValidationMethod::NONE
@ NONE
No validation.
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::DiscoveredPlayerInfo
Definition: ExternalMediaPlayerCommon.h:59
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::PlayerInfoBase::localPlayerId
std::string localPlayerId
The opaque token that uniquely identifies the local external player app.
Definition: ExternalMediaPlayerCommon.h:50
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::PlayerInfo::PlayerInfo
PlayerInfo(const std::string &localPlayerId="", const std::string &spiVersion="", bool supported=false)
Definition: ExternalMediaPlayerCommon.h:82
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::PlayerInfo::skillToken
std::string skillToken
An opaque token for the domain or skill that is presently associated with this player.
Definition: ExternalMediaPlayerCommon.h:91
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::validationMethodToString
std::string validationMethodToString(ValidationMethod value)
Converts the ValidationMethod enum to a string representation.
Definition: ExternalMediaPlayerCommon.h:33
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::PlayerInfoBase::spiVersion
std::string spiVersion
The service provider interface (SPI) version.
Definition: ExternalMediaPlayerCommon.h:53
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::ValidationMethod
ValidationMethod
Enum describing the available validation methods for External Media Players.
Definition: ExternalMediaPlayerCommon.h:23
alexaClientSDK::acsdkExternalMediaPlayerInterfaces::PlayerInfo::playerSupported
bool playerSupported
Definition: ExternalMediaPlayerCommon.h:98

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