Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| (...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 115 void SetLocalDescription(SetSessionDescriptionObserver* observer, | 115 void SetLocalDescription(SetSessionDescriptionObserver* observer, |
| 116 SessionDescriptionInterface* desc) override; | 116 SessionDescriptionInterface* desc) override; |
| 117 void SetRemoteDescription(SetSessionDescriptionObserver* observer, | 117 void SetRemoteDescription(SetSessionDescriptionObserver* observer, |
| 118 SessionDescriptionInterface* desc) override; | 118 SessionDescriptionInterface* desc) override; |
| 119 bool SetConfiguration( | 119 bool SetConfiguration( |
| 120 const PeerConnectionInterface::RTCConfiguration& config) override; | 120 const PeerConnectionInterface::RTCConfiguration& config) override; |
| 121 bool AddIceCandidate(const IceCandidateInterface* candidate) override; | 121 bool AddIceCandidate(const IceCandidateInterface* candidate) override; |
| 122 | 122 |
| 123 void RegisterUMAObserver(UMAObserver* observer) override; | 123 void RegisterUMAObserver(UMAObserver* observer) override; |
| 124 | 124 |
| 125 bool StartRtcEventLog(rtc::PlatformFile file) override; | |
| 126 void StopRtcEventLog() override; | |
| 127 | |
| 125 void Close() override; | 128 void Close() override; |
| 126 | 129 |
| 127 // Virtual for unit tests. | 130 // Virtual for unit tests. |
| 128 virtual const std::vector<rtc::scoped_refptr<DataChannel>>& | 131 virtual const std::vector<rtc::scoped_refptr<DataChannel>>& |
| 129 sctp_data_channels() const { | 132 sctp_data_channels() const { |
| 130 return sctp_data_channels_; | 133 return sctp_data_channels_; |
| 131 }; | 134 }; |
| 132 | 135 |
| 133 protected: | 136 protected: |
| 134 ~PeerConnection() override; | 137 ~PeerConnection() override; |
| (...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 322 TrackInfos* GetRemoteTracks(cricket::MediaType media_type); | 325 TrackInfos* GetRemoteTracks(cricket::MediaType media_type); |
| 323 TrackInfos* GetLocalTracks(cricket::MediaType media_type); | 326 TrackInfos* GetLocalTracks(cricket::MediaType media_type); |
| 324 const TrackInfo* FindTrackInfo(const TrackInfos& infos, | 327 const TrackInfo* FindTrackInfo(const TrackInfos& infos, |
| 325 const std::string& stream_label, | 328 const std::string& stream_label, |
| 326 const std::string track_id) const; | 329 const std::string track_id) const; |
| 327 | 330 |
| 328 // Returns the specified SCTP DataChannel in sctp_data_channels_, | 331 // Returns the specified SCTP DataChannel in sctp_data_channels_, |
| 329 // or nullptr if not found. | 332 // or nullptr if not found. |
| 330 DataChannel* FindDataChannelBySid(int sid) const; | 333 DataChannel* FindDataChannelBySid(int sid) const; |
| 331 | 334 |
| 335 // Starts recording an Rtc EventLog using the supplied platform file. | |
|
terelius
2016/03/10 10:42:32
RtcEventLog as one word maybe?
| |
| 336 // This function should only be called from the worker thread. | |
| 337 bool StartRtcEventLog_w(rtc::PlatformFile file); | |
| 338 // Starts recording an Rtc EventLog using the supplied platform file. | |
| 339 // This function should only be called from the worker thread. | |
| 340 void StopRtcEventLog_w(); | |
| 341 | |
| 332 // Storing the factory as a scoped reference pointer ensures that the memory | 342 // Storing the factory as a scoped reference pointer ensures that the memory |
| 333 // in the PeerConnectionFactoryImpl remains available as long as the | 343 // in the PeerConnectionFactoryImpl remains available as long as the |
| 334 // PeerConnection is running. It is passed to PeerConnection as a raw pointer. | 344 // PeerConnection is running. It is passed to PeerConnection as a raw pointer. |
| 335 // However, since the reference counting is done in the | 345 // However, since the reference counting is done in the |
| 336 // PeerConnectionFactoryInterface all instances created using the raw pointer | 346 // PeerConnectionFactoryInterface all instances created using the raw pointer |
| 337 // will refer to the same reference count. | 347 // will refer to the same reference count. |
| 338 rtc::scoped_refptr<PeerConnectionFactory> factory_; | 348 rtc::scoped_refptr<PeerConnectionFactory> factory_; |
| 339 PeerConnectionObserver* observer_; | 349 PeerConnectionObserver* observer_; |
| 340 UMAObserver* uma_observer_; | 350 UMAObserver* uma_observer_; |
| 341 SignalingState signaling_state_; | 351 SignalingState signaling_state_; |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 376 // because its destruction fires signals (such as VoiceChannelDestroyed) | 386 // because its destruction fires signals (such as VoiceChannelDestroyed) |
| 377 // which will trigger some final actions in PeerConnection... | 387 // which will trigger some final actions in PeerConnection... |
| 378 rtc::scoped_ptr<WebRtcSession> session_; | 388 rtc::scoped_ptr<WebRtcSession> session_; |
| 379 // ... But stats_ depends on session_ so it should be destroyed even earlier. | 389 // ... But stats_ depends on session_ so it should be destroyed even earlier. |
| 380 rtc::scoped_ptr<StatsCollector> stats_; | 390 rtc::scoped_ptr<StatsCollector> stats_; |
| 381 }; | 391 }; |
| 382 | 392 |
| 383 } // namespace webrtc | 393 } // namespace webrtc |
| 384 | 394 |
| 385 #endif // WEBRTC_API_PEERCONNECTION_H_ | 395 #endif // WEBRTC_API_PEERCONNECTION_H_ |
| OLD | NEW |