AlexaClientSDK  3.0.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
MockCaptionManager.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 ALEXA_CLIENT_SDK_CAPTIONS_IMPLEMENTATION_TEST_MOCKCAPTIONMANAGER_H_
17 #define ALEXA_CLIENT_SDK_CAPTIONS_IMPLEMENTATION_TEST_MOCKCAPTIONMANAGER_H_
18 
19 #include <vector>
20 #include <gmock/gmock.h>
21 
24 
25 namespace alexaClientSDK {
26 namespace captions {
27 namespace test {
28 
32  , public CaptionManagerInterface {
33 public:
36  MOCK_METHOD1(onParsed, void(const CaptionFrame&));
38 
41  MOCK_METHOD1(setCaptionPresenter, void(const std::shared_ptr<CaptionPresenterInterface>&));
42  MOCK_METHOD2(onCaption, void(uint64_t sourceId, const captions::CaptionData&));
45  void(const std::vector<std::shared_ptr<avsCommon::utils::mediaPlayer::MediaPlayerInterface>>&));
46  MOCK_METHOD1(addMediaPlayer, void(const std::shared_ptr<avsCommon::utils::mediaPlayer::MediaPlayerInterface>&));
47  MOCK_METHOD1(removeMediaPlayer, void(const std::shared_ptr<avsCommon::utils::mediaPlayer::MediaPlayerInterface>&));
50 
57  void(
58  SourceId,
64 };
65 
66 } // namespace test
67 } // namespace captions
68 } // namespace alexaClientSDK
69 #endif // ALEXA_CLIENT_SDK_CAPTIONS_IMPLEMENTATION_TEST_MOCKCAPTIONMANAGER_H_
MOCK_METHOD4(onPlaybackError, void(SourceId, const avsCommon::utils::mediaPlayer::ErrorType &, std::string, const avsCommon::utils::mediaPlayer::MediaPlayerState &))
virtual void onFirstByteRead(SourceId id, const MediaPlayerState &state)=0
virtual void setCaptionPresenter(const std::shared_ptr< CaptionPresenterInterface > &presenter)=0
Definition: AmdMetricWrapperTest.cpp:24
::std::string string
Definition: gtest-port.h:1097
MOCK_METHOD2(onCaption, void(uint64_t sourceId, const captions::CaptionData &))
virtual void onCaption(CaptionFrame::MediaPlayerSourceId sourceId, const CaptionData &captionData)=0
virtual void onParsed(const CaptionFrame &captionFrame)=0
Definition: CaptionManagerInterface.h:32
virtual void onPlaybackError(SourceId id, const ErrorType &type, std::string error, const MediaPlayerState &state)=0
virtual void onPlaybackFinished(SourceId id, const MediaPlayerState &state)=0
Definition: CaptionFrame.h:33
Definition: CaptionData.h:30
MOCK_METHOD1(onParsed, void(const CaptionFrame &))
virtual void onPlaybackStarted(SourceId id, const MediaPlayerState &state)=0
virtual void setMediaPlayers(const std::vector< std::shared_ptr< avsCommon::utils::mediaPlayer::MediaPlayerInterface >> &mediaPlayers)=0
MediaPlayerInterface::SourceId SourceId
A type that identifies which source is currently being operated on.
Definition: MediaPlayerObserverInterface.h:49
Whether or not curl logs should be emitted.
Definition: AVSConnectionManager.h:36
virtual void addMediaPlayer(const std::shared_ptr< avsCommon::utils::mediaPlayer::MediaPlayerInterface > &mediaPlayer)=0
Definition: MockCaptionManager.h:29
virtual void removeMediaPlayer(const std::shared_ptr< avsCommon::utils::mediaPlayer::MediaPlayerInterface > &mediaPlayer)=0
ErrorType
Identifies the specific type of error in a PlaybackFailed event.
Definition: ErrorTypes.h:28
Definition: CaptionFrameParseListenerInterface.h:27

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