Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(51)

Side by Side Diff: content/shell/test_runner/mock_webrtc_peer_connection_handler.h

Issue 2759953003: Interface RTCRtpReceiver and RTCPeerConnection.getReceivers() added. (Closed)
Patch Set: DISALLOW_COPY_AND_ASSIGN Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_SHELL_TEST_RUNNER_MOCK_WEBRTC_PEER_CONNECTION_HANDLER_H_ 5 #ifndef CONTENT_SHELL_TEST_RUNNER_MOCK_WEBRTC_PEER_CONNECTION_HANDLER_H_
6 #define CONTENT_SHELL_TEST_RUNNER_MOCK_WEBRTC_PEER_CONNECTION_HANDLER_H_ 6 #define CONTENT_SHELL_TEST_RUNNER_MOCK_WEBRTC_PEER_CONNECTION_HANDLER_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 blink::WebRTCErrorType setConfiguration( 54 blink::WebRTCErrorType setConfiguration(
55 const blink::WebRTCConfiguration& configuration) override; 55 const blink::WebRTCConfiguration& configuration) override;
56 bool addICECandidate(const blink::WebRTCICECandidate& ice_candidate) override; 56 bool addICECandidate(const blink::WebRTCICECandidate& ice_candidate) override;
57 bool addICECandidate(const blink::WebRTCVoidRequest& request, 57 bool addICECandidate(const blink::WebRTCVoidRequest& request,
58 const blink::WebRTCICECandidate& ice_candidate) override; 58 const blink::WebRTCICECandidate& ice_candidate) override;
59 bool addStream(const blink::WebMediaStream& stream, 59 bool addStream(const blink::WebMediaStream& stream,
60 const blink::WebMediaConstraints& constraints) override; 60 const blink::WebMediaConstraints& constraints) override;
61 void removeStream(const blink::WebMediaStream& stream) override; 61 void removeStream(const blink::WebMediaStream& stream) override;
62 void getStats(const blink::WebRTCStatsRequest& request) override; 62 void getStats(const blink::WebRTCStatsRequest& request) override;
63 void getStats(std::unique_ptr<blink::WebRTCStatsReportCallback>) override; 63 void getStats(std::unique_ptr<blink::WebRTCStatsReportCallback>) override;
64 blink::WebVector<std::unique_ptr<blink::WebRTCRtpReceiver>> getReceivers()
65 override;
64 blink::WebRTCDataChannelHandler* createDataChannel( 66 blink::WebRTCDataChannelHandler* createDataChannel(
65 const blink::WebString& label, 67 const blink::WebString& label,
66 const blink::WebRTCDataChannelInit& init) override; 68 const blink::WebRTCDataChannelInit& init) override;
67 blink::WebRTCDTMFSenderHandler* createDTMFSender( 69 blink::WebRTCDTMFSenderHandler* createDTMFSender(
68 const blink::WebMediaStreamTrack& track) override; 70 const blink::WebMediaStreamTrack& track) override;
69 void stop() override; 71 void stop() override;
70 72
71 private: 73 private:
72 MockWebRTCPeerConnectionHandler(); 74 MockWebRTCPeerConnectionHandler();
73 75
(...skipping 16 matching lines...) Expand all
90 92
91 blink::WebRTCPeerConnectionHandlerClient* client_; 93 blink::WebRTCPeerConnectionHandlerClient* client_;
92 bool stopped_; 94 bool stopped_;
93 blink::WebRTCSessionDescription local_description_; 95 blink::WebRTCSessionDescription local_description_;
94 blink::WebRTCSessionDescription remote_description_; 96 blink::WebRTCSessionDescription remote_description_;
95 int stream_count_; 97 int stream_count_;
96 TestInterfaces* interfaces_; 98 TestInterfaces* interfaces_;
97 typedef std::map<std::string, blink::WebMediaStream> StreamMap; 99 typedef std::map<std::string, blink::WebMediaStream> StreamMap;
98 StreamMap local_streams_; 100 StreamMap local_streams_;
99 StreamMap remote_streams_; 101 StreamMap remote_streams_;
102 std::map<std::string, uintptr_t> receiver_id_by_track_;
100 103
101 base::WeakPtrFactory<MockWebRTCPeerConnectionHandler> weak_factory_; 104 base::WeakPtrFactory<MockWebRTCPeerConnectionHandler> weak_factory_;
102 105
103 DISALLOW_COPY_AND_ASSIGN(MockWebRTCPeerConnectionHandler); 106 DISALLOW_COPY_AND_ASSIGN(MockWebRTCPeerConnectionHandler);
104 }; 107 };
105 108
106 } // namespace test_runner 109 } // namespace test_runner
107 110
108 #endif // CONTENT_SHELL_TEST_RUNNER_MOCK_WEBRTC_PEER_CONNECTION_HANDLER_H_ 111 #endif // CONTENT_SHELL_TEST_RUNNER_MOCK_WEBRTC_PEER_CONNECTION_HANDLER_H_
OLDNEW
« no previous file with comments | « content/renderer/media/webrtc/rtc_rtp_receiver.cc ('k') | content/shell/test_runner/mock_webrtc_peer_connection_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698