OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_RENDERER_MEDIA_RTC_PEER_CONNECTION_HANDLER_H_ | 5 #ifndef CONTENT_RENDERER_MEDIA_RTC_PEER_CONNECTION_HANDLER_H_ |
6 #define CONTENT_RENDERER_MEDIA_RTC_PEER_CONNECTION_HANDLER_H_ | 6 #define CONTENT_RENDERER_MEDIA_RTC_PEER_CONNECTION_HANDLER_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
(...skipping 14 matching lines...) Expand all Loading... |
25 #include "third_party/WebKit/public/platform/WebRTCPeerConnectionHandler.h" | 25 #include "third_party/WebKit/public/platform/WebRTCPeerConnectionHandler.h" |
26 #include "third_party/WebKit/public/platform/WebRTCStatsRequest.h" | 26 #include "third_party/WebKit/public/platform/WebRTCStatsRequest.h" |
27 #include "third_party/WebKit/public/platform/WebRTCStatsResponse.h" | 27 #include "third_party/WebKit/public/platform/WebRTCStatsResponse.h" |
28 | 28 |
29 namespace blink { | 29 namespace blink { |
30 class WebFrame; | 30 class WebFrame; |
31 class WebRTCAnswerOptions; | 31 class WebRTCAnswerOptions; |
32 class WebRTCDataChannelHandler; | 32 class WebRTCDataChannelHandler; |
33 class WebRTCOfferOptions; | 33 class WebRTCOfferOptions; |
34 class WebRTCPeerConnectionHandlerClient; | 34 class WebRTCPeerConnectionHandlerClient; |
| 35 class WebRTCStats; |
35 } | 36 } |
36 | 37 |
37 namespace content { | 38 namespace content { |
38 | 39 |
39 class PeerConnectionDependencyFactory; | 40 class PeerConnectionDependencyFactory; |
40 class PeerConnectionTracker; | 41 class PeerConnectionTracker; |
41 class RemoteMediaStreamImpl; | 42 class RemoteMediaStreamImpl; |
42 class RtcDataChannelHandler; | 43 class RtcDataChannelHandler; |
43 class WebRtcMediaStreamAdapter; | 44 class WebRtcMediaStreamAdapter; |
44 | 45 |
45 // Mockable wrapper for blink::WebRTCStatsResponse | 46 // Mockable wrapper for blink::WebRTCStatsResponse |
46 class CONTENT_EXPORT LocalRTCStatsResponse | 47 class CONTENT_EXPORT LocalRTCStatsResponse |
47 : public NON_EXPORTED_BASE(rtc::RefCountInterface) { | 48 : public NON_EXPORTED_BASE(rtc::RefCountInterface) { |
48 public: | 49 public: |
49 explicit LocalRTCStatsResponse(const blink::WebRTCStatsResponse& impl) | 50 explicit LocalRTCStatsResponse(const blink::WebRTCStatsResponse& impl) |
50 : impl_(impl) { | 51 : impl_(impl) { |
51 } | 52 } |
52 | 53 |
53 virtual blink::WebRTCStatsResponse webKitStatsResponse() const; | 54 virtual blink::WebRTCStatsResponse webKitStatsResponse() const; |
54 virtual size_t addReport(blink::WebString type, blink::WebString id, | 55 virtual void addStats(const blink::WebRTCStats& stats); |
55 double timestamp); | |
56 virtual void addStatistic(size_t report, | |
57 blink::WebString name, blink::WebString value); | |
58 | 56 |
59 protected: | 57 protected: |
60 ~LocalRTCStatsResponse() override {} | 58 ~LocalRTCStatsResponse() override {} |
61 // Constructor for creating mocks. | 59 // Constructor for creating mocks. |
62 LocalRTCStatsResponse() {} | 60 LocalRTCStatsResponse() {} |
63 | 61 |
64 private: | 62 private: |
65 blink::WebRTCStatsResponse impl_; | 63 blink::WebRTCStatsResponse impl_; |
66 }; | 64 }; |
67 | 65 |
(...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
287 bool ice_state_seen_[webrtc::PeerConnectionInterface::kIceConnectionMax] = {}; | 285 bool ice_state_seen_[webrtc::PeerConnectionInterface::kIceConnectionMax] = {}; |
288 | 286 |
289 base::WeakPtrFactory<RTCPeerConnectionHandler> weak_factory_; | 287 base::WeakPtrFactory<RTCPeerConnectionHandler> weak_factory_; |
290 | 288 |
291 DISALLOW_COPY_AND_ASSIGN(RTCPeerConnectionHandler); | 289 DISALLOW_COPY_AND_ASSIGN(RTCPeerConnectionHandler); |
292 }; | 290 }; |
293 | 291 |
294 } // namespace content | 292 } // namespace content |
295 | 293 |
296 #endif // CONTENT_RENDERER_MEDIA_RTC_PEER_CONNECTION_HANDLER_H_ | 294 #endif // CONTENT_RENDERER_MEDIA_RTC_PEER_CONNECTION_HANDLER_H_ |
OLD | NEW |