feat(hos_client_create, hos_client_destory): 多次调用destory不会导致重复释放

This commit is contained in:
彭宣正
2020-12-14 17:24:58 +08:00
parent 505d529c32
commit 10b370e486
55976 changed files with 8544395 additions and 2 deletions

View File

@@ -0,0 +1,76 @@
add_project(aws-cpp-sdk-kinesis-video-signaling "C++ SDK for the AWS kinesis-video-signaling service" aws-cpp-sdk-core)
file(GLOB AWS_KINESIS-VIDEO-SIGNALING_HEADERS
"include/aws/kinesis-video-signaling/*.h"
)
file(GLOB AWS_KINESIS-VIDEO-SIGNALING_MODEL_HEADERS
"include/aws/kinesis-video-signaling/model/*.h"
)
file(GLOB AWS_KINESIS-VIDEO-SIGNALING_SOURCE
"source/*.cpp"
)
file(GLOB AWS_KINESIS-VIDEO-SIGNALING_MODEL_SOURCE
"source/model/*.cpp"
)
file(GLOB KINESIS-VIDEO-SIGNALING_UNIFIED_HEADERS
${AWS_KINESIS-VIDEO-SIGNALING_HEADERS}
${AWS_KINESIS-VIDEO-SIGNALING_MODEL_HEADERS}
)
file(GLOB KINESIS-VIDEO-SIGNALING_UNITY_SRC
${AWS_KINESIS-VIDEO-SIGNALING_SOURCE}
${AWS_KINESIS-VIDEO-SIGNALING_MODEL_SOURCE}
)
if(ENABLE_UNITY_BUILD)
enable_unity_build("KINESIS-VIDEO-SIGNALING" KINESIS-VIDEO-SIGNALING_UNITY_SRC)
endif()
file(GLOB KINESIS-VIDEO-SIGNALING_SRC
${KINESIS-VIDEO-SIGNALING_UNIFIED_HEADERS}
${KINESIS-VIDEO-SIGNALING_UNITY_SRC}
)
if(WIN32)
#if we are compiling for visual studio, create a sane directory tree.
if(MSVC)
source_group("Header Files\\aws\\kinesis-video-signaling" FILES ${AWS_KINESIS-VIDEO-SIGNALING_HEADERS})
source_group("Header Files\\aws\\kinesis-video-signaling\\model" FILES ${AWS_KINESIS-VIDEO-SIGNALING_MODEL_HEADERS})
source_group("Source Files" FILES ${AWS_KINESIS-VIDEO-SIGNALING_SOURCE})
source_group("Source Files\\model" FILES ${AWS_KINESIS-VIDEO-SIGNALING_MODEL_SOURCE})
endif(MSVC)
endif()
set(KINESIS-VIDEO-SIGNALING_INCLUDES
"${CMAKE_CURRENT_SOURCE_DIR}/include/"
)
add_library(${PROJECT_NAME} ${KINESIS-VIDEO-SIGNALING_SRC})
add_library(AWS::${PROJECT_NAME} ALIAS ${PROJECT_NAME})
set_compiler_flags(${PROJECT_NAME})
set_compiler_warnings(${PROJECT_NAME})
if(USE_WINDOWS_DLL_SEMANTICS AND BUILD_SHARED_LIBS)
target_compile_definitions(${PROJECT_NAME} PRIVATE "AWS_KINESISVIDEOSIGNALINGCHANNELS_EXPORTS")
endif()
target_include_directories(${PROJECT_NAME} PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
$<INSTALL_INTERFACE:include>)
target_link_libraries(${PROJECT_NAME} PRIVATE ${PLATFORM_DEP_LIBS} ${PROJECT_LIBS})
setup_install()
install (FILES ${AWS_KINESIS-VIDEO-SIGNALING_HEADERS} DESTINATION ${INCLUDE_DIRECTORY}/aws/kinesis-video-signaling)
install (FILES ${AWS_KINESIS-VIDEO-SIGNALING_MODEL_HEADERS} DESTINATION ${INCLUDE_DIRECTORY}/aws/kinesis-video-signaling/model)
do_packaging()

View File

@@ -0,0 +1,226 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannels_EXPORTS.h>
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannelsErrors.h>
#include <aws/core/client/AWSError.h>
#include <aws/core/client/ClientConfiguration.h>
#include <aws/core/client/AWSClient.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/kinesis-video-signaling/model/GetIceServerConfigResult.h>
#include <aws/kinesis-video-signaling/model/SendAlexaOfferToMasterResult.h>
#include <aws/core/client/AsyncCallerContext.h>
#include <aws/core/http/HttpTypes.h>
#include <future>
#include <functional>
namespace Aws
{
namespace Http
{
class HttpClient;
class HttpClientFactory;
} // namespace Http
namespace Utils
{
template< typename R, typename E> class Outcome;
namespace Threading
{
class Executor;
} // namespace Threading
} // namespace Utils
namespace Auth
{
class AWSCredentials;
class AWSCredentialsProvider;
} // namespace Auth
namespace Client
{
class RetryStrategy;
} // namespace Client
namespace KinesisVideoSignalingChannels
{
namespace Model
{
class GetIceServerConfigRequest;
class SendAlexaOfferToMasterRequest;
typedef Aws::Utils::Outcome<GetIceServerConfigResult, KinesisVideoSignalingChannelsError> GetIceServerConfigOutcome;
typedef Aws::Utils::Outcome<SendAlexaOfferToMasterResult, KinesisVideoSignalingChannelsError> SendAlexaOfferToMasterOutcome;
typedef std::future<GetIceServerConfigOutcome> GetIceServerConfigOutcomeCallable;
typedef std::future<SendAlexaOfferToMasterOutcome> SendAlexaOfferToMasterOutcomeCallable;
} // namespace Model
class KinesisVideoSignalingChannelsClient;
typedef std::function<void(const KinesisVideoSignalingChannelsClient*, const Model::GetIceServerConfigRequest&, const Model::GetIceServerConfigOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > GetIceServerConfigResponseReceivedHandler;
typedef std::function<void(const KinesisVideoSignalingChannelsClient*, const Model::SendAlexaOfferToMasterRequest&, const Model::SendAlexaOfferToMasterOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > SendAlexaOfferToMasterResponseReceivedHandler;
/**
* <p>Kinesis Video Streams Signaling Service is a intermediate service that
* establishes a communication channel for discovering peers, transmitting offers
* and answers in order to establish peer-to-peer connection in webRTC
* technology.</p>
*/
class AWS_KINESISVIDEOSIGNALINGCHANNELS_API KinesisVideoSignalingChannelsClient : public Aws::Client::AWSJsonClient
{
public:
typedef Aws::Client::AWSJsonClient BASECLASS;
/**
* Initializes client to use DefaultCredentialProviderChain, with default http client factory, and optional client config. If client config
* is not specified, it will be initialized to default values.
*/
KinesisVideoSignalingChannelsClient(const Aws::Client::ClientConfiguration& clientConfiguration = Aws::Client::ClientConfiguration());
/**
* Initializes client to use SimpleAWSCredentialsProvider, with default http client factory, and optional client config. If client config
* is not specified, it will be initialized to default values.
*/
KinesisVideoSignalingChannelsClient(const Aws::Auth::AWSCredentials& credentials, const Aws::Client::ClientConfiguration& clientConfiguration = Aws::Client::ClientConfiguration());
/**
* Initializes client to use specified credentials provider with specified client config. If http client factory is not supplied,
* the default http client factory will be used
*/
KinesisVideoSignalingChannelsClient(const std::shared_ptr<Aws::Auth::AWSCredentialsProvider>& credentialsProvider,
const Aws::Client::ClientConfiguration& clientConfiguration = Aws::Client::ClientConfiguration());
virtual ~KinesisVideoSignalingChannelsClient();
/**
* <p>Gets the Interactive Connectivity Establishment (ICE) server configuration
* information, including URIs, username, and password which can be used to
* configure the WebRTC connection. The ICE component uses this configuration
* information to setup the WebRTC connection, including authenticating with the
* Traversal Using Relays around NAT (TURN) relay server. </p> <p>TURN is a
* protocol that is used to improve the connectivity of peer-to-peer applications.
* By providing a cloud-based relay service, TURN ensures that a connection can be
* established even when one or more peers are incapable of a direct peer-to-peer
* connection. For more information, see <a
* href="https://tools.ietf.org/html/draft-uberti-rtcweb-turn-rest-00">A REST API
* For Access To TURN Services</a>.</p> <p> You can invoke this API to establish a
* fallback mechanism in case either of the peers is unable to establish a direct
* peer-to-peer connection over a signaling channel. You must specify either a
* signaling channel ARN or the client ID in order to invoke this
* API.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/kinesis-video-signaling-2019-12-04/GetIceServerConfig">AWS
* API Reference</a></p>
*/
virtual Model::GetIceServerConfigOutcome GetIceServerConfig(const Model::GetIceServerConfigRequest& request) const;
/**
* <p>Gets the Interactive Connectivity Establishment (ICE) server configuration
* information, including URIs, username, and password which can be used to
* configure the WebRTC connection. The ICE component uses this configuration
* information to setup the WebRTC connection, including authenticating with the
* Traversal Using Relays around NAT (TURN) relay server. </p> <p>TURN is a
* protocol that is used to improve the connectivity of peer-to-peer applications.
* By providing a cloud-based relay service, TURN ensures that a connection can be
* established even when one or more peers are incapable of a direct peer-to-peer
* connection. For more information, see <a
* href="https://tools.ietf.org/html/draft-uberti-rtcweb-turn-rest-00">A REST API
* For Access To TURN Services</a>.</p> <p> You can invoke this API to establish a
* fallback mechanism in case either of the peers is unable to establish a direct
* peer-to-peer connection over a signaling channel. You must specify either a
* signaling channel ARN or the client ID in order to invoke this
* API.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/kinesis-video-signaling-2019-12-04/GetIceServerConfig">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::GetIceServerConfigOutcomeCallable GetIceServerConfigCallable(const Model::GetIceServerConfigRequest& request) const;
/**
* <p>Gets the Interactive Connectivity Establishment (ICE) server configuration
* information, including URIs, username, and password which can be used to
* configure the WebRTC connection. The ICE component uses this configuration
* information to setup the WebRTC connection, including authenticating with the
* Traversal Using Relays around NAT (TURN) relay server. </p> <p>TURN is a
* protocol that is used to improve the connectivity of peer-to-peer applications.
* By providing a cloud-based relay service, TURN ensures that a connection can be
* established even when one or more peers are incapable of a direct peer-to-peer
* connection. For more information, see <a
* href="https://tools.ietf.org/html/draft-uberti-rtcweb-turn-rest-00">A REST API
* For Access To TURN Services</a>.</p> <p> You can invoke this API to establish a
* fallback mechanism in case either of the peers is unable to establish a direct
* peer-to-peer connection over a signaling channel. You must specify either a
* signaling channel ARN or the client ID in order to invoke this
* API.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/kinesis-video-signaling-2019-12-04/GetIceServerConfig">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void GetIceServerConfigAsync(const Model::GetIceServerConfigRequest& request, const GetIceServerConfigResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
/**
* <p>This API allows you to connect WebRTC-enabled devices with Alexa display
* devices. When invoked, it sends the Alexa Session Description Protocol (SDP)
* offer to the master peer. The offer is delivered as soon as the master is
* connected to the specified signaling channel. This API returns the SDP answer
* from the connected master. If the master is not connected to the signaling
* channel, redelivery requests are made until the message expires.</p><p><h3>See
* Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/kinesis-video-signaling-2019-12-04/SendAlexaOfferToMaster">AWS
* API Reference</a></p>
*/
virtual Model::SendAlexaOfferToMasterOutcome SendAlexaOfferToMaster(const Model::SendAlexaOfferToMasterRequest& request) const;
/**
* <p>This API allows you to connect WebRTC-enabled devices with Alexa display
* devices. When invoked, it sends the Alexa Session Description Protocol (SDP)
* offer to the master peer. The offer is delivered as soon as the master is
* connected to the specified signaling channel. This API returns the SDP answer
* from the connected master. If the master is not connected to the signaling
* channel, redelivery requests are made until the message expires.</p><p><h3>See
* Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/kinesis-video-signaling-2019-12-04/SendAlexaOfferToMaster">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::SendAlexaOfferToMasterOutcomeCallable SendAlexaOfferToMasterCallable(const Model::SendAlexaOfferToMasterRequest& request) const;
/**
* <p>This API allows you to connect WebRTC-enabled devices with Alexa display
* devices. When invoked, it sends the Alexa Session Description Protocol (SDP)
* offer to the master peer. The offer is delivered as soon as the master is
* connected to the specified signaling channel. This API returns the SDP answer
* from the connected master. If the master is not connected to the signaling
* channel, redelivery requests are made until the message expires.</p><p><h3>See
* Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/kinesis-video-signaling-2019-12-04/SendAlexaOfferToMaster">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void SendAlexaOfferToMasterAsync(const Model::SendAlexaOfferToMasterRequest& request, const SendAlexaOfferToMasterResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
void OverrideEndpoint(const Aws::String& endpoint);
private:
void init(const Aws::Client::ClientConfiguration& clientConfiguration);
void GetIceServerConfigAsyncHelper(const Model::GetIceServerConfigRequest& request, const GetIceServerConfigResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
void SendAlexaOfferToMasterAsyncHelper(const Model::SendAlexaOfferToMasterRequest& request, const SendAlexaOfferToMasterResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
Aws::String m_uri;
Aws::String m_configScheme;
std::shared_ptr<Aws::Utils::Threading::Executor> m_executor;
};
} // namespace KinesisVideoSignalingChannels
} // namespace Aws

View File

@@ -0,0 +1,21 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannels_EXPORTS.h>
#include <aws/core/Region.h>
#include <aws/core/utils/memory/stl/AWSString.h>
namespace Aws
{
namespace KinesisVideoSignalingChannels
{
namespace KinesisVideoSignalingChannelsEndpoint
{
AWS_KINESISVIDEOSIGNALINGCHANNELS_API Aws::String ForRegion(const Aws::String& regionName, bool useDualStack = false);
} // namespace KinesisVideoSignalingChannelsEndpoint
} // namespace KinesisVideoSignalingChannels
} // namespace Aws

View File

@@ -0,0 +1,23 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannels_EXPORTS.h>
#include <aws/core/client/AWSErrorMarshaller.h>
namespace Aws
{
namespace Client
{
class AWS_KINESISVIDEOSIGNALINGCHANNELS_API KinesisVideoSignalingChannelsErrorMarshaller : public Aws::Client::JsonErrorMarshaller
{
public:
Aws::Client::AWSError<Aws::Client::CoreErrors> FindErrorByName(const char* exceptionName) const override;
};
} // namespace Client
} // namespace Aws

View File

@@ -0,0 +1,76 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/core/client/AWSError.h>
#include <aws/core/client/CoreErrors.h>
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannels_EXPORTS.h>
namespace Aws
{
namespace KinesisVideoSignalingChannels
{
enum class KinesisVideoSignalingChannelsErrors
{
//From Core//
//////////////////////////////////////////////////////////////////////////////////////////
INCOMPLETE_SIGNATURE = 0,
INTERNAL_FAILURE = 1,
INVALID_ACTION = 2,
INVALID_CLIENT_TOKEN_ID = 3,
INVALID_PARAMETER_COMBINATION = 4,
INVALID_QUERY_PARAMETER = 5,
INVALID_PARAMETER_VALUE = 6,
MISSING_ACTION = 7, // SDK should never allow
MISSING_AUTHENTICATION_TOKEN = 8, // SDK should never allow
MISSING_PARAMETER = 9, // SDK should never allow
OPT_IN_REQUIRED = 10,
REQUEST_EXPIRED = 11,
SERVICE_UNAVAILABLE = 12,
THROTTLING = 13,
VALIDATION = 14,
ACCESS_DENIED = 15,
RESOURCE_NOT_FOUND = 16,
UNRECOGNIZED_CLIENT = 17,
MALFORMED_QUERY_STRING = 18,
SLOW_DOWN = 19,
REQUEST_TIME_TOO_SKEWED = 20,
INVALID_SIGNATURE = 21,
SIGNATURE_DOES_NOT_MATCH = 22,
INVALID_ACCESS_KEY_ID = 23,
REQUEST_TIMEOUT = 24,
NETWORK_CONNECTION = 99,
UNKNOWN = 100,
///////////////////////////////////////////////////////////////////////////////////////////
CLIENT_LIMIT_EXCEEDED= static_cast<int>(Aws::Client::CoreErrors::SERVICE_EXTENSION_START_RANGE) + 1,
INVALID_ARGUMENT,
INVALID_CLIENT,
NOT_AUTHORIZED,
SESSION_EXPIRED
};
class AWS_KINESISVIDEOSIGNALINGCHANNELS_API KinesisVideoSignalingChannelsError : public Aws::Client::AWSError<KinesisVideoSignalingChannelsErrors>
{
public:
KinesisVideoSignalingChannelsError() {}
KinesisVideoSignalingChannelsError(const Aws::Client::AWSError<Aws::Client::CoreErrors>& rhs) : Aws::Client::AWSError<KinesisVideoSignalingChannelsErrors>(rhs) {}
KinesisVideoSignalingChannelsError(Aws::Client::AWSError<Aws::Client::CoreErrors>&& rhs) : Aws::Client::AWSError<KinesisVideoSignalingChannelsErrors>(rhs) {}
KinesisVideoSignalingChannelsError(const Aws::Client::AWSError<KinesisVideoSignalingChannelsErrors>& rhs) : Aws::Client::AWSError<KinesisVideoSignalingChannelsErrors>(rhs) {}
KinesisVideoSignalingChannelsError(Aws::Client::AWSError<KinesisVideoSignalingChannelsErrors>&& rhs) : Aws::Client::AWSError<KinesisVideoSignalingChannelsErrors>(rhs) {}
template <typename T>
T GetModeledError();
};
namespace KinesisVideoSignalingChannelsErrorMapper
{
AWS_KINESISVIDEOSIGNALINGCHANNELS_API Aws::Client::AWSError<Aws::Client::CoreErrors> GetErrorForName(const char* errorName);
}
} // namespace KinesisVideoSignalingChannels
} // namespace Aws

View File

@@ -0,0 +1,42 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannels_EXPORTS.h>
#include <aws/core/AmazonSerializableWebServiceRequest.h>
#include <aws/core/utils/UnreferencedParam.h>
#include <aws/core/http/HttpRequest.h>
namespace Aws
{
namespace KinesisVideoSignalingChannels
{
class AWS_KINESISVIDEOSIGNALINGCHANNELS_API KinesisVideoSignalingChannelsRequest : public Aws::AmazonSerializableWebServiceRequest
{
public:
virtual ~KinesisVideoSignalingChannelsRequest () {}
void AddParametersToRequest(Aws::Http::HttpRequest& httpRequest) const { AWS_UNREFERENCED_PARAM(httpRequest); }
inline Aws::Http::HeaderValueCollection GetHeaders() const override
{
auto headers = GetRequestSpecificHeaders();
if(headers.size() == 0 || (headers.size() > 0 && headers.count(Aws::Http::CONTENT_TYPE_HEADER) == 0))
{
headers.emplace(Aws::Http::HeaderValuePair(Aws::Http::CONTENT_TYPE_HEADER, Aws::AMZN_JSON_CONTENT_TYPE_1_1 ));
}
headers.emplace(Aws::Http::HeaderValuePair(Aws::Http::API_VERSION_HEADER, "2019-12-04"));
return headers;
}
protected:
virtual Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const { return Aws::Http::HeaderValueCollection(); }
};
} // namespace KinesisVideoSignalingChannels
} // namespace Aws

View File

@@ -0,0 +1,29 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#ifdef _MSC_VER
//disable windows complaining about max template size.
#pragma warning (disable : 4503)
#endif // _MSC_VER
#if defined (USE_WINDOWS_DLL_SEMANTICS) || defined (_WIN32)
#ifdef _MSC_VER
#pragma warning(disable : 4251)
#endif // _MSC_VER
#ifdef USE_IMPORT_EXPORT
#ifdef AWS_KINESISVIDEOSIGNALINGCHANNELS_EXPORTS
#define AWS_KINESISVIDEOSIGNALINGCHANNELS_API __declspec(dllexport)
#else
#define AWS_KINESISVIDEOSIGNALINGCHANNELS_API __declspec(dllimport)
#endif /* AWS_KINESISVIDEOSIGNALINGCHANNELS_EXPORTS */
#else
#define AWS_KINESISVIDEOSIGNALINGCHANNELS_API
#endif // USE_IMPORT_EXPORT
#else // defined (USE_WINDOWS_DLL_SEMANTICS) || defined (WIN32)
#define AWS_KINESISVIDEOSIGNALINGCHANNELS_API
#endif // defined (USE_WINDOWS_DLL_SEMANTICS) || defined (WIN32)

View File

@@ -0,0 +1,228 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannels_EXPORTS.h>
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannelsRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/kinesis-video-signaling/model/Service.h>
#include <utility>
namespace Aws
{
namespace KinesisVideoSignalingChannels
{
namespace Model
{
/**
*/
class AWS_KINESISVIDEOSIGNALINGCHANNELS_API GetIceServerConfigRequest : public KinesisVideoSignalingChannelsRequest
{
public:
GetIceServerConfigRequest();
// Service request name is the Operation name which will send this request out,
// each operation should has unique request name, so that we can get operation's name from this request.
// Note: this is not true for response, multiple operations may have the same response name,
// so we can not get operation's name from response.
inline virtual const char* GetServiceRequestName() const override { return "GetIceServerConfig"; }
Aws::String SerializePayload() const override;
/**
* <p>The ARN of the signaling channel to be used for the peer-to-peer connection
* between configured peers. </p>
*/
inline const Aws::String& GetChannelARN() const{ return m_channelARN; }
/**
* <p>The ARN of the signaling channel to be used for the peer-to-peer connection
* between configured peers. </p>
*/
inline bool ChannelARNHasBeenSet() const { return m_channelARNHasBeenSet; }
/**
* <p>The ARN of the signaling channel to be used for the peer-to-peer connection
* between configured peers. </p>
*/
inline void SetChannelARN(const Aws::String& value) { m_channelARNHasBeenSet = true; m_channelARN = value; }
/**
* <p>The ARN of the signaling channel to be used for the peer-to-peer connection
* between configured peers. </p>
*/
inline void SetChannelARN(Aws::String&& value) { m_channelARNHasBeenSet = true; m_channelARN = std::move(value); }
/**
* <p>The ARN of the signaling channel to be used for the peer-to-peer connection
* between configured peers. </p>
*/
inline void SetChannelARN(const char* value) { m_channelARNHasBeenSet = true; m_channelARN.assign(value); }
/**
* <p>The ARN of the signaling channel to be used for the peer-to-peer connection
* between configured peers. </p>
*/
inline GetIceServerConfigRequest& WithChannelARN(const Aws::String& value) { SetChannelARN(value); return *this;}
/**
* <p>The ARN of the signaling channel to be used for the peer-to-peer connection
* between configured peers. </p>
*/
inline GetIceServerConfigRequest& WithChannelARN(Aws::String&& value) { SetChannelARN(std::move(value)); return *this;}
/**
* <p>The ARN of the signaling channel to be used for the peer-to-peer connection
* between configured peers. </p>
*/
inline GetIceServerConfigRequest& WithChannelARN(const char* value) { SetChannelARN(value); return *this;}
/**
* <p>Unique identifier for the viewer. Must be unique within the signaling
* channel.</p>
*/
inline const Aws::String& GetClientId() const{ return m_clientId; }
/**
* <p>Unique identifier for the viewer. Must be unique within the signaling
* channel.</p>
*/
inline bool ClientIdHasBeenSet() const { return m_clientIdHasBeenSet; }
/**
* <p>Unique identifier for the viewer. Must be unique within the signaling
* channel.</p>
*/
inline void SetClientId(const Aws::String& value) { m_clientIdHasBeenSet = true; m_clientId = value; }
/**
* <p>Unique identifier for the viewer. Must be unique within the signaling
* channel.</p>
*/
inline void SetClientId(Aws::String&& value) { m_clientIdHasBeenSet = true; m_clientId = std::move(value); }
/**
* <p>Unique identifier for the viewer. Must be unique within the signaling
* channel.</p>
*/
inline void SetClientId(const char* value) { m_clientIdHasBeenSet = true; m_clientId.assign(value); }
/**
* <p>Unique identifier for the viewer. Must be unique within the signaling
* channel.</p>
*/
inline GetIceServerConfigRequest& WithClientId(const Aws::String& value) { SetClientId(value); return *this;}
/**
* <p>Unique identifier for the viewer. Must be unique within the signaling
* channel.</p>
*/
inline GetIceServerConfigRequest& WithClientId(Aws::String&& value) { SetClientId(std::move(value)); return *this;}
/**
* <p>Unique identifier for the viewer. Must be unique within the signaling
* channel.</p>
*/
inline GetIceServerConfigRequest& WithClientId(const char* value) { SetClientId(value); return *this;}
/**
* <p>Specifies the desired service. Currently, <code>TURN</code> is the only valid
* value.</p>
*/
inline const Service& GetService() const{ return m_service; }
/**
* <p>Specifies the desired service. Currently, <code>TURN</code> is the only valid
* value.</p>
*/
inline bool ServiceHasBeenSet() const { return m_serviceHasBeenSet; }
/**
* <p>Specifies the desired service. Currently, <code>TURN</code> is the only valid
* value.</p>
*/
inline void SetService(const Service& value) { m_serviceHasBeenSet = true; m_service = value; }
/**
* <p>Specifies the desired service. Currently, <code>TURN</code> is the only valid
* value.</p>
*/
inline void SetService(Service&& value) { m_serviceHasBeenSet = true; m_service = std::move(value); }
/**
* <p>Specifies the desired service. Currently, <code>TURN</code> is the only valid
* value.</p>
*/
inline GetIceServerConfigRequest& WithService(const Service& value) { SetService(value); return *this;}
/**
* <p>Specifies the desired service. Currently, <code>TURN</code> is the only valid
* value.</p>
*/
inline GetIceServerConfigRequest& WithService(Service&& value) { SetService(std::move(value)); return *this;}
/**
* <p>An optional user ID to be associated with the credentials.</p>
*/
inline const Aws::String& GetUsername() const{ return m_username; }
/**
* <p>An optional user ID to be associated with the credentials.</p>
*/
inline bool UsernameHasBeenSet() const { return m_usernameHasBeenSet; }
/**
* <p>An optional user ID to be associated with the credentials.</p>
*/
inline void SetUsername(const Aws::String& value) { m_usernameHasBeenSet = true; m_username = value; }
/**
* <p>An optional user ID to be associated with the credentials.</p>
*/
inline void SetUsername(Aws::String&& value) { m_usernameHasBeenSet = true; m_username = std::move(value); }
/**
* <p>An optional user ID to be associated with the credentials.</p>
*/
inline void SetUsername(const char* value) { m_usernameHasBeenSet = true; m_username.assign(value); }
/**
* <p>An optional user ID to be associated with the credentials.</p>
*/
inline GetIceServerConfigRequest& WithUsername(const Aws::String& value) { SetUsername(value); return *this;}
/**
* <p>An optional user ID to be associated with the credentials.</p>
*/
inline GetIceServerConfigRequest& WithUsername(Aws::String&& value) { SetUsername(std::move(value)); return *this;}
/**
* <p>An optional user ID to be associated with the credentials.</p>
*/
inline GetIceServerConfigRequest& WithUsername(const char* value) { SetUsername(value); return *this;}
private:
Aws::String m_channelARN;
bool m_channelARNHasBeenSet;
Aws::String m_clientId;
bool m_clientIdHasBeenSet;
Service m_service;
bool m_serviceHasBeenSet;
Aws::String m_username;
bool m_usernameHasBeenSet;
};
} // namespace Model
} // namespace KinesisVideoSignalingChannels
} // namespace Aws

View File

@@ -0,0 +1,78 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannels_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSVector.h>
#include <aws/kinesis-video-signaling/model/IceServer.h>
#include <utility>
namespace Aws
{
template<typename RESULT_TYPE>
class AmazonWebServiceResult;
namespace Utils
{
namespace Json
{
class JsonValue;
} // namespace Json
} // namespace Utils
namespace KinesisVideoSignalingChannels
{
namespace Model
{
class AWS_KINESISVIDEOSIGNALINGCHANNELS_API GetIceServerConfigResult
{
public:
GetIceServerConfigResult();
GetIceServerConfigResult(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
GetIceServerConfigResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
/**
* <p>The list of ICE server information objects.</p>
*/
inline const Aws::Vector<IceServer>& GetIceServerList() const{ return m_iceServerList; }
/**
* <p>The list of ICE server information objects.</p>
*/
inline void SetIceServerList(const Aws::Vector<IceServer>& value) { m_iceServerList = value; }
/**
* <p>The list of ICE server information objects.</p>
*/
inline void SetIceServerList(Aws::Vector<IceServer>&& value) { m_iceServerList = std::move(value); }
/**
* <p>The list of ICE server information objects.</p>
*/
inline GetIceServerConfigResult& WithIceServerList(const Aws::Vector<IceServer>& value) { SetIceServerList(value); return *this;}
/**
* <p>The list of ICE server information objects.</p>
*/
inline GetIceServerConfigResult& WithIceServerList(Aws::Vector<IceServer>&& value) { SetIceServerList(std::move(value)); return *this;}
/**
* <p>The list of ICE server information objects.</p>
*/
inline GetIceServerConfigResult& AddIceServerList(const IceServer& value) { m_iceServerList.push_back(value); return *this; }
/**
* <p>The list of ICE server information objects.</p>
*/
inline GetIceServerConfigResult& AddIceServerList(IceServer&& value) { m_iceServerList.push_back(std::move(value)); return *this; }
private:
Aws::Vector<IceServer> m_iceServerList;
};
} // namespace Model
} // namespace KinesisVideoSignalingChannels
} // namespace Aws

View File

@@ -0,0 +1,237 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannels_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSVector.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
namespace Utils
{
namespace Json
{
class JsonValue;
class JsonView;
} // namespace Json
} // namespace Utils
namespace KinesisVideoSignalingChannels
{
namespace Model
{
/**
* <p>A structure for the ICE server connection data.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/kinesis-video-signaling-2019-12-04/IceServer">AWS
* API Reference</a></p>
*/
class AWS_KINESISVIDEOSIGNALINGCHANNELS_API IceServer
{
public:
IceServer();
IceServer(Aws::Utils::Json::JsonView jsonValue);
IceServer& operator=(Aws::Utils::Json::JsonView jsonValue);
Aws::Utils::Json::JsonValue Jsonize() const;
/**
* <p>An array of URIs, in the form specified in the <a
* href="https://tools.ietf.org/html/draft-petithuguenin-behave-turn-uris-03">I-D.petithuguenin-behave-turn-uris</a>
* spec. These URIs provide the different addresses and/or protocols that can be
* used to reach the TURN server.</p>
*/
inline const Aws::Vector<Aws::String>& GetUris() const{ return m_uris; }
/**
* <p>An array of URIs, in the form specified in the <a
* href="https://tools.ietf.org/html/draft-petithuguenin-behave-turn-uris-03">I-D.petithuguenin-behave-turn-uris</a>
* spec. These URIs provide the different addresses and/or protocols that can be
* used to reach the TURN server.</p>
*/
inline bool UrisHasBeenSet() const { return m_urisHasBeenSet; }
/**
* <p>An array of URIs, in the form specified in the <a
* href="https://tools.ietf.org/html/draft-petithuguenin-behave-turn-uris-03">I-D.petithuguenin-behave-turn-uris</a>
* spec. These URIs provide the different addresses and/or protocols that can be
* used to reach the TURN server.</p>
*/
inline void SetUris(const Aws::Vector<Aws::String>& value) { m_urisHasBeenSet = true; m_uris = value; }
/**
* <p>An array of URIs, in the form specified in the <a
* href="https://tools.ietf.org/html/draft-petithuguenin-behave-turn-uris-03">I-D.petithuguenin-behave-turn-uris</a>
* spec. These URIs provide the different addresses and/or protocols that can be
* used to reach the TURN server.</p>
*/
inline void SetUris(Aws::Vector<Aws::String>&& value) { m_urisHasBeenSet = true; m_uris = std::move(value); }
/**
* <p>An array of URIs, in the form specified in the <a
* href="https://tools.ietf.org/html/draft-petithuguenin-behave-turn-uris-03">I-D.petithuguenin-behave-turn-uris</a>
* spec. These URIs provide the different addresses and/or protocols that can be
* used to reach the TURN server.</p>
*/
inline IceServer& WithUris(const Aws::Vector<Aws::String>& value) { SetUris(value); return *this;}
/**
* <p>An array of URIs, in the form specified in the <a
* href="https://tools.ietf.org/html/draft-petithuguenin-behave-turn-uris-03">I-D.petithuguenin-behave-turn-uris</a>
* spec. These URIs provide the different addresses and/or protocols that can be
* used to reach the TURN server.</p>
*/
inline IceServer& WithUris(Aws::Vector<Aws::String>&& value) { SetUris(std::move(value)); return *this;}
/**
* <p>An array of URIs, in the form specified in the <a
* href="https://tools.ietf.org/html/draft-petithuguenin-behave-turn-uris-03">I-D.petithuguenin-behave-turn-uris</a>
* spec. These URIs provide the different addresses and/or protocols that can be
* used to reach the TURN server.</p>
*/
inline IceServer& AddUris(const Aws::String& value) { m_urisHasBeenSet = true; m_uris.push_back(value); return *this; }
/**
* <p>An array of URIs, in the form specified in the <a
* href="https://tools.ietf.org/html/draft-petithuguenin-behave-turn-uris-03">I-D.petithuguenin-behave-turn-uris</a>
* spec. These URIs provide the different addresses and/or protocols that can be
* used to reach the TURN server.</p>
*/
inline IceServer& AddUris(Aws::String&& value) { m_urisHasBeenSet = true; m_uris.push_back(std::move(value)); return *this; }
/**
* <p>An array of URIs, in the form specified in the <a
* href="https://tools.ietf.org/html/draft-petithuguenin-behave-turn-uris-03">I-D.petithuguenin-behave-turn-uris</a>
* spec. These URIs provide the different addresses and/or protocols that can be
* used to reach the TURN server.</p>
*/
inline IceServer& AddUris(const char* value) { m_urisHasBeenSet = true; m_uris.push_back(value); return *this; }
/**
* <p>A username to login to the ICE server.</p>
*/
inline const Aws::String& GetUsername() const{ return m_username; }
/**
* <p>A username to login to the ICE server.</p>
*/
inline bool UsernameHasBeenSet() const { return m_usernameHasBeenSet; }
/**
* <p>A username to login to the ICE server.</p>
*/
inline void SetUsername(const Aws::String& value) { m_usernameHasBeenSet = true; m_username = value; }
/**
* <p>A username to login to the ICE server.</p>
*/
inline void SetUsername(Aws::String&& value) { m_usernameHasBeenSet = true; m_username = std::move(value); }
/**
* <p>A username to login to the ICE server.</p>
*/
inline void SetUsername(const char* value) { m_usernameHasBeenSet = true; m_username.assign(value); }
/**
* <p>A username to login to the ICE server.</p>
*/
inline IceServer& WithUsername(const Aws::String& value) { SetUsername(value); return *this;}
/**
* <p>A username to login to the ICE server.</p>
*/
inline IceServer& WithUsername(Aws::String&& value) { SetUsername(std::move(value)); return *this;}
/**
* <p>A username to login to the ICE server.</p>
*/
inline IceServer& WithUsername(const char* value) { SetUsername(value); return *this;}
/**
* <p>A password to login to the ICE server.</p>
*/
inline const Aws::String& GetPassword() const{ return m_password; }
/**
* <p>A password to login to the ICE server.</p>
*/
inline bool PasswordHasBeenSet() const { return m_passwordHasBeenSet; }
/**
* <p>A password to login to the ICE server.</p>
*/
inline void SetPassword(const Aws::String& value) { m_passwordHasBeenSet = true; m_password = value; }
/**
* <p>A password to login to the ICE server.</p>
*/
inline void SetPassword(Aws::String&& value) { m_passwordHasBeenSet = true; m_password = std::move(value); }
/**
* <p>A password to login to the ICE server.</p>
*/
inline void SetPassword(const char* value) { m_passwordHasBeenSet = true; m_password.assign(value); }
/**
* <p>A password to login to the ICE server.</p>
*/
inline IceServer& WithPassword(const Aws::String& value) { SetPassword(value); return *this;}
/**
* <p>A password to login to the ICE server.</p>
*/
inline IceServer& WithPassword(Aws::String&& value) { SetPassword(std::move(value)); return *this;}
/**
* <p>A password to login to the ICE server.</p>
*/
inline IceServer& WithPassword(const char* value) { SetPassword(value); return *this;}
/**
* <p>The period of time, in seconds, during which the username and password are
* valid.</p>
*/
inline int GetTtl() const{ return m_ttl; }
/**
* <p>The period of time, in seconds, during which the username and password are
* valid.</p>
*/
inline bool TtlHasBeenSet() const { return m_ttlHasBeenSet; }
/**
* <p>The period of time, in seconds, during which the username and password are
* valid.</p>
*/
inline void SetTtl(int value) { m_ttlHasBeenSet = true; m_ttl = value; }
/**
* <p>The period of time, in seconds, during which the username and password are
* valid.</p>
*/
inline IceServer& WithTtl(int value) { SetTtl(value); return *this;}
private:
Aws::Vector<Aws::String> m_uris;
bool m_urisHasBeenSet;
Aws::String m_username;
bool m_usernameHasBeenSet;
Aws::String m_password;
bool m_passwordHasBeenSet;
int m_ttl;
bool m_ttlHasBeenSet;
};
} // namespace Model
} // namespace KinesisVideoSignalingChannels
} // namespace Aws

View File

@@ -0,0 +1,179 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannels_EXPORTS.h>
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannelsRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
namespace KinesisVideoSignalingChannels
{
namespace Model
{
/**
*/
class AWS_KINESISVIDEOSIGNALINGCHANNELS_API SendAlexaOfferToMasterRequest : public KinesisVideoSignalingChannelsRequest
{
public:
SendAlexaOfferToMasterRequest();
// Service request name is the Operation name which will send this request out,
// each operation should has unique request name, so that we can get operation's name from this request.
// Note: this is not true for response, multiple operations may have the same response name,
// so we can not get operation's name from response.
inline virtual const char* GetServiceRequestName() const override { return "SendAlexaOfferToMaster"; }
Aws::String SerializePayload() const override;
/**
* <p>The ARN of the signaling channel by which Alexa and the master peer
* communicate.</p>
*/
inline const Aws::String& GetChannelARN() const{ return m_channelARN; }
/**
* <p>The ARN of the signaling channel by which Alexa and the master peer
* communicate.</p>
*/
inline bool ChannelARNHasBeenSet() const { return m_channelARNHasBeenSet; }
/**
* <p>The ARN of the signaling channel by which Alexa and the master peer
* communicate.</p>
*/
inline void SetChannelARN(const Aws::String& value) { m_channelARNHasBeenSet = true; m_channelARN = value; }
/**
* <p>The ARN of the signaling channel by which Alexa and the master peer
* communicate.</p>
*/
inline void SetChannelARN(Aws::String&& value) { m_channelARNHasBeenSet = true; m_channelARN = std::move(value); }
/**
* <p>The ARN of the signaling channel by which Alexa and the master peer
* communicate.</p>
*/
inline void SetChannelARN(const char* value) { m_channelARNHasBeenSet = true; m_channelARN.assign(value); }
/**
* <p>The ARN of the signaling channel by which Alexa and the master peer
* communicate.</p>
*/
inline SendAlexaOfferToMasterRequest& WithChannelARN(const Aws::String& value) { SetChannelARN(value); return *this;}
/**
* <p>The ARN of the signaling channel by which Alexa and the master peer
* communicate.</p>
*/
inline SendAlexaOfferToMasterRequest& WithChannelARN(Aws::String&& value) { SetChannelARN(std::move(value)); return *this;}
/**
* <p>The ARN of the signaling channel by which Alexa and the master peer
* communicate.</p>
*/
inline SendAlexaOfferToMasterRequest& WithChannelARN(const char* value) { SetChannelARN(value); return *this;}
/**
* <p>The unique identifier for the sender client.</p>
*/
inline const Aws::String& GetSenderClientId() const{ return m_senderClientId; }
/**
* <p>The unique identifier for the sender client.</p>
*/
inline bool SenderClientIdHasBeenSet() const { return m_senderClientIdHasBeenSet; }
/**
* <p>The unique identifier for the sender client.</p>
*/
inline void SetSenderClientId(const Aws::String& value) { m_senderClientIdHasBeenSet = true; m_senderClientId = value; }
/**
* <p>The unique identifier for the sender client.</p>
*/
inline void SetSenderClientId(Aws::String&& value) { m_senderClientIdHasBeenSet = true; m_senderClientId = std::move(value); }
/**
* <p>The unique identifier for the sender client.</p>
*/
inline void SetSenderClientId(const char* value) { m_senderClientIdHasBeenSet = true; m_senderClientId.assign(value); }
/**
* <p>The unique identifier for the sender client.</p>
*/
inline SendAlexaOfferToMasterRequest& WithSenderClientId(const Aws::String& value) { SetSenderClientId(value); return *this;}
/**
* <p>The unique identifier for the sender client.</p>
*/
inline SendAlexaOfferToMasterRequest& WithSenderClientId(Aws::String&& value) { SetSenderClientId(std::move(value)); return *this;}
/**
* <p>The unique identifier for the sender client.</p>
*/
inline SendAlexaOfferToMasterRequest& WithSenderClientId(const char* value) { SetSenderClientId(value); return *this;}
/**
* <p>The base64-encoded SDP offer content.</p>
*/
inline const Aws::String& GetMessagePayload() const{ return m_messagePayload; }
/**
* <p>The base64-encoded SDP offer content.</p>
*/
inline bool MessagePayloadHasBeenSet() const { return m_messagePayloadHasBeenSet; }
/**
* <p>The base64-encoded SDP offer content.</p>
*/
inline void SetMessagePayload(const Aws::String& value) { m_messagePayloadHasBeenSet = true; m_messagePayload = value; }
/**
* <p>The base64-encoded SDP offer content.</p>
*/
inline void SetMessagePayload(Aws::String&& value) { m_messagePayloadHasBeenSet = true; m_messagePayload = std::move(value); }
/**
* <p>The base64-encoded SDP offer content.</p>
*/
inline void SetMessagePayload(const char* value) { m_messagePayloadHasBeenSet = true; m_messagePayload.assign(value); }
/**
* <p>The base64-encoded SDP offer content.</p>
*/
inline SendAlexaOfferToMasterRequest& WithMessagePayload(const Aws::String& value) { SetMessagePayload(value); return *this;}
/**
* <p>The base64-encoded SDP offer content.</p>
*/
inline SendAlexaOfferToMasterRequest& WithMessagePayload(Aws::String&& value) { SetMessagePayload(std::move(value)); return *this;}
/**
* <p>The base64-encoded SDP offer content.</p>
*/
inline SendAlexaOfferToMasterRequest& WithMessagePayload(const char* value) { SetMessagePayload(value); return *this;}
private:
Aws::String m_channelARN;
bool m_channelARNHasBeenSet;
Aws::String m_senderClientId;
bool m_senderClientIdHasBeenSet;
Aws::String m_messagePayload;
bool m_messagePayloadHasBeenSet;
};
} // namespace Model
} // namespace KinesisVideoSignalingChannels
} // namespace Aws

View File

@@ -0,0 +1,77 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannels_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
template<typename RESULT_TYPE>
class AmazonWebServiceResult;
namespace Utils
{
namespace Json
{
class JsonValue;
} // namespace Json
} // namespace Utils
namespace KinesisVideoSignalingChannels
{
namespace Model
{
class AWS_KINESISVIDEOSIGNALINGCHANNELS_API SendAlexaOfferToMasterResult
{
public:
SendAlexaOfferToMasterResult();
SendAlexaOfferToMasterResult(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
SendAlexaOfferToMasterResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
/**
* <p>The base64-encoded SDP answer content.</p>
*/
inline const Aws::String& GetAnswer() const{ return m_answer; }
/**
* <p>The base64-encoded SDP answer content.</p>
*/
inline void SetAnswer(const Aws::String& value) { m_answer = value; }
/**
* <p>The base64-encoded SDP answer content.</p>
*/
inline void SetAnswer(Aws::String&& value) { m_answer = std::move(value); }
/**
* <p>The base64-encoded SDP answer content.</p>
*/
inline void SetAnswer(const char* value) { m_answer.assign(value); }
/**
* <p>The base64-encoded SDP answer content.</p>
*/
inline SendAlexaOfferToMasterResult& WithAnswer(const Aws::String& value) { SetAnswer(value); return *this;}
/**
* <p>The base64-encoded SDP answer content.</p>
*/
inline SendAlexaOfferToMasterResult& WithAnswer(Aws::String&& value) { SetAnswer(std::move(value)); return *this;}
/**
* <p>The base64-encoded SDP answer content.</p>
*/
inline SendAlexaOfferToMasterResult& WithAnswer(const char* value) { SetAnswer(value); return *this;}
private:
Aws::String m_answer;
};
} // namespace Model
} // namespace KinesisVideoSignalingChannels
} // namespace Aws

View File

@@ -0,0 +1,30 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannels_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>
namespace Aws
{
namespace KinesisVideoSignalingChannels
{
namespace Model
{
enum class Service
{
NOT_SET,
TURN
};
namespace ServiceMapper
{
AWS_KINESISVIDEOSIGNALINGCHANNELS_API Service GetServiceForName(const Aws::String& name);
AWS_KINESISVIDEOSIGNALINGCHANNELS_API Aws::String GetNameForService(Service value);
} // namespace ServiceMapper
} // namespace Model
} // namespace KinesisVideoSignalingChannels
} // namespace Aws

View File

@@ -0,0 +1,152 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/core/utils/Outcome.h>
#include <aws/core/auth/AWSAuthSigner.h>
#include <aws/core/client/CoreErrors.h>
#include <aws/core/client/RetryStrategy.h>
#include <aws/core/http/HttpClient.h>
#include <aws/core/http/HttpResponse.h>
#include <aws/core/http/HttpClientFactory.h>
#include <aws/core/auth/AWSCredentialsProviderChain.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/core/utils/memory/stl/AWSStringStream.h>
#include <aws/core/utils/threading/Executor.h>
#include <aws/core/utils/DNS.h>
#include <aws/core/utils/logging/LogMacros.h>
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannelsClient.h>
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannelsEndpoint.h>
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannelsErrorMarshaller.h>
#include <aws/kinesis-video-signaling/model/GetIceServerConfigRequest.h>
#include <aws/kinesis-video-signaling/model/SendAlexaOfferToMasterRequest.h>
using namespace Aws;
using namespace Aws::Auth;
using namespace Aws::Client;
using namespace Aws::KinesisVideoSignalingChannels;
using namespace Aws::KinesisVideoSignalingChannels::Model;
using namespace Aws::Http;
using namespace Aws::Utils::Json;
static const char* SERVICE_NAME = "kinesisvideo";
static const char* ALLOCATION_TAG = "KinesisVideoSignalingChannelsClient";
KinesisVideoSignalingChannelsClient::KinesisVideoSignalingChannelsClient(const Client::ClientConfiguration& clientConfiguration) :
BASECLASS(clientConfiguration,
Aws::MakeShared<AWSAuthV4Signer>(ALLOCATION_TAG, Aws::MakeShared<DefaultAWSCredentialsProviderChain>(ALLOCATION_TAG),
SERVICE_NAME, Aws::Region::ComputeSignerRegion(clientConfiguration.region)),
Aws::MakeShared<KinesisVideoSignalingChannelsErrorMarshaller>(ALLOCATION_TAG)),
m_executor(clientConfiguration.executor)
{
init(clientConfiguration);
}
KinesisVideoSignalingChannelsClient::KinesisVideoSignalingChannelsClient(const AWSCredentials& credentials, const Client::ClientConfiguration& clientConfiguration) :
BASECLASS(clientConfiguration,
Aws::MakeShared<AWSAuthV4Signer>(ALLOCATION_TAG, Aws::MakeShared<SimpleAWSCredentialsProvider>(ALLOCATION_TAG, credentials),
SERVICE_NAME, Aws::Region::ComputeSignerRegion(clientConfiguration.region)),
Aws::MakeShared<KinesisVideoSignalingChannelsErrorMarshaller>(ALLOCATION_TAG)),
m_executor(clientConfiguration.executor)
{
init(clientConfiguration);
}
KinesisVideoSignalingChannelsClient::KinesisVideoSignalingChannelsClient(const std::shared_ptr<AWSCredentialsProvider>& credentialsProvider,
const Client::ClientConfiguration& clientConfiguration) :
BASECLASS(clientConfiguration,
Aws::MakeShared<AWSAuthV4Signer>(ALLOCATION_TAG, credentialsProvider,
SERVICE_NAME, Aws::Region::ComputeSignerRegion(clientConfiguration.region)),
Aws::MakeShared<KinesisVideoSignalingChannelsErrorMarshaller>(ALLOCATION_TAG)),
m_executor(clientConfiguration.executor)
{
init(clientConfiguration);
}
KinesisVideoSignalingChannelsClient::~KinesisVideoSignalingChannelsClient()
{
}
void KinesisVideoSignalingChannelsClient::init(const ClientConfiguration& config)
{
SetServiceClientName("Kinesis Video Signaling");
m_configScheme = SchemeMapper::ToString(config.scheme);
if (config.endpointOverride.empty())
{
m_uri = m_configScheme + "://" + KinesisVideoSignalingChannelsEndpoint::ForRegion(config.region, config.useDualStack);
}
else
{
OverrideEndpoint(config.endpointOverride);
}
}
void KinesisVideoSignalingChannelsClient::OverrideEndpoint(const Aws::String& endpoint)
{
if (endpoint.compare(0, 7, "http://") == 0 || endpoint.compare(0, 8, "https://") == 0)
{
m_uri = endpoint;
}
else
{
m_uri = m_configScheme + "://" + endpoint;
}
}
GetIceServerConfigOutcome KinesisVideoSignalingChannelsClient::GetIceServerConfig(const GetIceServerConfigRequest& request) const
{
Aws::Http::URI uri = m_uri;
Aws::StringStream ss;
ss << "/v1/get-ice-server-config";
uri.SetPath(uri.GetPath() + ss.str());
return GetIceServerConfigOutcome(MakeRequest(uri, request, Aws::Http::HttpMethod::HTTP_POST, Aws::Auth::SIGV4_SIGNER));
}
GetIceServerConfigOutcomeCallable KinesisVideoSignalingChannelsClient::GetIceServerConfigCallable(const GetIceServerConfigRequest& request) const
{
auto task = Aws::MakeShared< std::packaged_task< GetIceServerConfigOutcome() > >(ALLOCATION_TAG, [this, request](){ return this->GetIceServerConfig(request); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void KinesisVideoSignalingChannelsClient::GetIceServerConfigAsync(const GetIceServerConfigRequest& request, const GetIceServerConfigResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, request, handler, context](){ this->GetIceServerConfigAsyncHelper( request, handler, context ); } );
}
void KinesisVideoSignalingChannelsClient::GetIceServerConfigAsyncHelper(const GetIceServerConfigRequest& request, const GetIceServerConfigResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, request, GetIceServerConfig(request), context);
}
SendAlexaOfferToMasterOutcome KinesisVideoSignalingChannelsClient::SendAlexaOfferToMaster(const SendAlexaOfferToMasterRequest& request) const
{
Aws::Http::URI uri = m_uri;
Aws::StringStream ss;
ss << "/v1/send-alexa-offer-to-master";
uri.SetPath(uri.GetPath() + ss.str());
return SendAlexaOfferToMasterOutcome(MakeRequest(uri, request, Aws::Http::HttpMethod::HTTP_POST, Aws::Auth::SIGV4_SIGNER));
}
SendAlexaOfferToMasterOutcomeCallable KinesisVideoSignalingChannelsClient::SendAlexaOfferToMasterCallable(const SendAlexaOfferToMasterRequest& request) const
{
auto task = Aws::MakeShared< std::packaged_task< SendAlexaOfferToMasterOutcome() > >(ALLOCATION_TAG, [this, request](){ return this->SendAlexaOfferToMaster(request); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void KinesisVideoSignalingChannelsClient::SendAlexaOfferToMasterAsync(const SendAlexaOfferToMasterRequest& request, const SendAlexaOfferToMasterResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, request, handler, context](){ this->SendAlexaOfferToMasterAsyncHelper( request, handler, context ); } );
}
void KinesisVideoSignalingChannelsClient::SendAlexaOfferToMasterAsyncHelper(const SendAlexaOfferToMasterRequest& request, const SendAlexaOfferToMasterResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, request, SendAlexaOfferToMaster(request), context);
}

View File

@@ -0,0 +1,64 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannelsEndpoint.h>
#include <aws/core/utils/memory/stl/AWSStringStream.h>
#include <aws/core/utils/HashingUtils.h>
using namespace Aws;
using namespace Aws::KinesisVideoSignalingChannels;
namespace Aws
{
namespace KinesisVideoSignalingChannels
{
namespace KinesisVideoSignalingChannelsEndpoint
{
static const int CN_NORTH_1_HASH = Aws::Utils::HashingUtils::HashString("cn-north-1");
static const int CN_NORTHWEST_1_HASH = Aws::Utils::HashingUtils::HashString("cn-northwest-1");
static const int US_ISO_EAST_1_HASH = Aws::Utils::HashingUtils::HashString("us-iso-east-1");
static const int US_ISOB_EAST_1_HASH = Aws::Utils::HashingUtils::HashString("us-isob-east-1");
Aws::String ForRegion(const Aws::String& regionName, bool useDualStack)
{
// Fallback to us-east-1 if global endpoint does not exists.
Aws::String region = regionName == Aws::Region::AWS_GLOBAL ? Aws::Region::US_EAST_1 : regionName;
auto hash = Aws::Utils::HashingUtils::HashString(region.c_str());
Aws::StringStream ss;
ss << "kinesisvideo" << ".";
if(useDualStack)
{
ss << "dualstack.";
}
ss << region;
if (hash == CN_NORTH_1_HASH || hash == CN_NORTHWEST_1_HASH)
{
ss << ".amazonaws.com.cn";
}
else if (hash == US_ISO_EAST_1_HASH)
{
ss << ".c2s.ic.gov";
}
else if (hash == US_ISOB_EAST_1_HASH)
{
ss << ".sc2s.sgov.gov";
}
else
{
ss << ".amazonaws.com";
}
return ss.str();
}
} // namespace KinesisVideoSignalingChannelsEndpoint
} // namespace KinesisVideoSignalingChannels
} // namespace Aws

View File

@@ -0,0 +1,22 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/core/client/AWSError.h>
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannelsErrorMarshaller.h>
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannelsErrors.h>
using namespace Aws::Client;
using namespace Aws::KinesisVideoSignalingChannels;
AWSError<CoreErrors> KinesisVideoSignalingChannelsErrorMarshaller::FindErrorByName(const char* errorName) const
{
AWSError<CoreErrors> error = KinesisVideoSignalingChannelsErrorMapper::GetErrorForName(errorName);
if(error.GetErrorType() != CoreErrors::UNKNOWN)
{
return error;
}
return AWSErrorMarshaller::FindErrorByName(errorName);
}

View File

@@ -0,0 +1,57 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/core/client/AWSError.h>
#include <aws/core/utils/HashingUtils.h>
#include <aws/kinesis-video-signaling/KinesisVideoSignalingChannelsErrors.h>
using namespace Aws::Client;
using namespace Aws::Utils;
using namespace Aws::KinesisVideoSignalingChannels;
namespace Aws
{
namespace KinesisVideoSignalingChannels
{
namespace KinesisVideoSignalingChannelsErrorMapper
{
static const int SESSION_EXPIRED_HASH = HashingUtils::HashString("SessionExpiredException");
static const int NOT_AUTHORIZED_HASH = HashingUtils::HashString("NotAuthorizedException");
static const int INVALID_CLIENT_HASH = HashingUtils::HashString("InvalidClientException");
static const int CLIENT_LIMIT_EXCEEDED_HASH = HashingUtils::HashString("ClientLimitExceededException");
static const int INVALID_ARGUMENT_HASH = HashingUtils::HashString("InvalidArgumentException");
AWSError<CoreErrors> GetErrorForName(const char* errorName)
{
int hashCode = HashingUtils::HashString(errorName);
if (hashCode == SESSION_EXPIRED_HASH)
{
return AWSError<CoreErrors>(static_cast<CoreErrors>(KinesisVideoSignalingChannelsErrors::SESSION_EXPIRED), false);
}
else if (hashCode == NOT_AUTHORIZED_HASH)
{
return AWSError<CoreErrors>(static_cast<CoreErrors>(KinesisVideoSignalingChannelsErrors::NOT_AUTHORIZED), false);
}
else if (hashCode == INVALID_CLIENT_HASH)
{
return AWSError<CoreErrors>(static_cast<CoreErrors>(KinesisVideoSignalingChannelsErrors::INVALID_CLIENT), false);
}
else if (hashCode == CLIENT_LIMIT_EXCEEDED_HASH)
{
return AWSError<CoreErrors>(static_cast<CoreErrors>(KinesisVideoSignalingChannelsErrors::CLIENT_LIMIT_EXCEEDED), false);
}
else if (hashCode == INVALID_ARGUMENT_HASH)
{
return AWSError<CoreErrors>(static_cast<CoreErrors>(KinesisVideoSignalingChannelsErrors::INVALID_ARGUMENT), false);
}
return AWSError<CoreErrors>(CoreErrors::UNKNOWN, false);
}
} // namespace KinesisVideoSignalingChannelsErrorMapper
} // namespace KinesisVideoSignalingChannels
} // namespace Aws

View File

@@ -0,0 +1,56 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/kinesis-video-signaling/model/GetIceServerConfigRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::KinesisVideoSignalingChannels::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
GetIceServerConfigRequest::GetIceServerConfigRequest() :
m_channelARNHasBeenSet(false),
m_clientIdHasBeenSet(false),
m_service(Service::NOT_SET),
m_serviceHasBeenSet(false),
m_usernameHasBeenSet(false)
{
}
Aws::String GetIceServerConfigRequest::SerializePayload() const
{
JsonValue payload;
if(m_channelARNHasBeenSet)
{
payload.WithString("ChannelARN", m_channelARN);
}
if(m_clientIdHasBeenSet)
{
payload.WithString("ClientId", m_clientId);
}
if(m_serviceHasBeenSet)
{
payload.WithString("Service", ServiceMapper::GetNameForService(m_service));
}
if(m_usernameHasBeenSet)
{
payload.WithString("Username", m_username);
}
return payload.View().WriteReadable();
}

View File

@@ -0,0 +1,43 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/kinesis-video-signaling/model/GetIceServerConfigResult.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/core/AmazonWebServiceResult.h>
#include <aws/core/utils/StringUtils.h>
#include <aws/core/utils/UnreferencedParam.h>
#include <utility>
using namespace Aws::KinesisVideoSignalingChannels::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
using namespace Aws;
GetIceServerConfigResult::GetIceServerConfigResult()
{
}
GetIceServerConfigResult::GetIceServerConfigResult(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
*this = result;
}
GetIceServerConfigResult& GetIceServerConfigResult::operator =(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
JsonView jsonValue = result.GetPayload().View();
if(jsonValue.ValueExists("IceServerList"))
{
Array<JsonView> iceServerListJsonList = jsonValue.GetArray("IceServerList");
for(unsigned iceServerListIndex = 0; iceServerListIndex < iceServerListJsonList.GetLength(); ++iceServerListIndex)
{
m_iceServerList.push_back(iceServerListJsonList[iceServerListIndex].AsObject());
}
}
return *this;
}

View File

@@ -0,0 +1,114 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/kinesis-video-signaling/model/IceServer.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
namespace Aws
{
namespace KinesisVideoSignalingChannels
{
namespace Model
{
IceServer::IceServer() :
m_urisHasBeenSet(false),
m_usernameHasBeenSet(false),
m_passwordHasBeenSet(false),
m_ttl(0),
m_ttlHasBeenSet(false)
{
}
IceServer::IceServer(JsonView jsonValue) :
m_urisHasBeenSet(false),
m_usernameHasBeenSet(false),
m_passwordHasBeenSet(false),
m_ttl(0),
m_ttlHasBeenSet(false)
{
*this = jsonValue;
}
IceServer& IceServer::operator =(JsonView jsonValue)
{
if(jsonValue.ValueExists("Uris"))
{
Array<JsonView> urisJsonList = jsonValue.GetArray("Uris");
for(unsigned urisIndex = 0; urisIndex < urisJsonList.GetLength(); ++urisIndex)
{
m_uris.push_back(urisJsonList[urisIndex].AsString());
}
m_urisHasBeenSet = true;
}
if(jsonValue.ValueExists("Username"))
{
m_username = jsonValue.GetString("Username");
m_usernameHasBeenSet = true;
}
if(jsonValue.ValueExists("Password"))
{
m_password = jsonValue.GetString("Password");
m_passwordHasBeenSet = true;
}
if(jsonValue.ValueExists("Ttl"))
{
m_ttl = jsonValue.GetInteger("Ttl");
m_ttlHasBeenSet = true;
}
return *this;
}
JsonValue IceServer::Jsonize() const
{
JsonValue payload;
if(m_urisHasBeenSet)
{
Array<JsonValue> urisJsonList(m_uris.size());
for(unsigned urisIndex = 0; urisIndex < urisJsonList.GetLength(); ++urisIndex)
{
urisJsonList[urisIndex].AsString(m_uris[urisIndex]);
}
payload.WithArray("Uris", std::move(urisJsonList));
}
if(m_usernameHasBeenSet)
{
payload.WithString("Username", m_username);
}
if(m_passwordHasBeenSet)
{
payload.WithString("Password", m_password);
}
if(m_ttlHasBeenSet)
{
payload.WithInteger("Ttl", m_ttl);
}
return payload;
}
} // namespace Model
} // namespace KinesisVideoSignalingChannels
} // namespace Aws

View File

@@ -0,0 +1,49 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/kinesis-video-signaling/model/SendAlexaOfferToMasterRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::KinesisVideoSignalingChannels::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
SendAlexaOfferToMasterRequest::SendAlexaOfferToMasterRequest() :
m_channelARNHasBeenSet(false),
m_senderClientIdHasBeenSet(false),
m_messagePayloadHasBeenSet(false)
{
}
Aws::String SendAlexaOfferToMasterRequest::SerializePayload() const
{
JsonValue payload;
if(m_channelARNHasBeenSet)
{
payload.WithString("ChannelARN", m_channelARN);
}
if(m_senderClientIdHasBeenSet)
{
payload.WithString("SenderClientId", m_senderClientId);
}
if(m_messagePayloadHasBeenSet)
{
payload.WithString("MessagePayload", m_messagePayload);
}
return payload.View().WriteReadable();
}

View File

@@ -0,0 +1,40 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/kinesis-video-signaling/model/SendAlexaOfferToMasterResult.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/core/AmazonWebServiceResult.h>
#include <aws/core/utils/StringUtils.h>
#include <aws/core/utils/UnreferencedParam.h>
#include <utility>
using namespace Aws::KinesisVideoSignalingChannels::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
using namespace Aws;
SendAlexaOfferToMasterResult::SendAlexaOfferToMasterResult()
{
}
SendAlexaOfferToMasterResult::SendAlexaOfferToMasterResult(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
*this = result;
}
SendAlexaOfferToMasterResult& SendAlexaOfferToMasterResult::operator =(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
JsonView jsonValue = result.GetPayload().View();
if(jsonValue.ValueExists("Answer"))
{
m_answer = jsonValue.GetString("Answer");
}
return *this;
}

View File

@@ -0,0 +1,63 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/kinesis-video-signaling/model/Service.h>
#include <aws/core/utils/HashingUtils.h>
#include <aws/core/Globals.h>
#include <aws/core/utils/EnumParseOverflowContainer.h>
using namespace Aws::Utils;
namespace Aws
{
namespace KinesisVideoSignalingChannels
{
namespace Model
{
namespace ServiceMapper
{
static const int TURN_HASH = HashingUtils::HashString("TURN");
Service GetServiceForName(const Aws::String& name)
{
int hashCode = HashingUtils::HashString(name.c_str());
if (hashCode == TURN_HASH)
{
return Service::TURN;
}
EnumParseOverflowContainer* overflowContainer = Aws::GetEnumOverflowContainer();
if(overflowContainer)
{
overflowContainer->StoreOverflow(hashCode, name);
return static_cast<Service>(hashCode);
}
return Service::NOT_SET;
}
Aws::String GetNameForService(Service enumValue)
{
switch(enumValue)
{
case Service::TURN:
return "TURN";
default:
EnumParseOverflowContainer* overflowContainer = Aws::GetEnumOverflowContainer();
if(overflowContainer)
{
return overflowContainer->RetrieveOverflow(static_cast<int>(enumValue));
}
return {};
}
}
} // namespace ServiceMapper
} // namespace Model
} // namespace KinesisVideoSignalingChannels
} // namespace Aws