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 #include "content/renderer/media/mock_media_stream_dependency_factory.h" | 5 #include "content/renderer/media/mock_media_stream_dependency_factory.h" |
6 #include "content/renderer/media/mock_peer_connection_impl.h" | 6 #include "content/renderer/media/mock_peer_connection_impl.h" |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
281 | 281 |
282 void MockPeerConnectionImpl::AddRemoteStream(MediaStreamInterface* stream) { | 282 void MockPeerConnectionImpl::AddRemoteStream(MediaStreamInterface* stream) { |
283 remote_streams_->AddStream(stream); | 283 remote_streams_->AddStream(stream); |
284 } | 284 } |
285 | 285 |
286 void MockPeerConnectionImpl::CreateOffer( | 286 void MockPeerConnectionImpl::CreateOffer( |
287 CreateSessionDescriptionObserver* observer, | 287 CreateSessionDescriptionObserver* observer, |
288 const MediaConstraintsInterface* constraints) { | 288 const MediaConstraintsInterface* constraints) { |
289 DCHECK(observer); | 289 DCHECK(observer); |
290 created_sessiondescription_.reset( | 290 created_sessiondescription_.reset( |
291 dependency_factory_->CreateSessionDescription("unknown", kDummyOffer)); | 291 dependency_factory_->CreateSessionDescription("unknown", kDummyOffer, |
| 292 NULL)); |
292 } | 293 } |
293 | 294 |
294 void MockPeerConnectionImpl::CreateAnswer( | 295 void MockPeerConnectionImpl::CreateAnswer( |
295 CreateSessionDescriptionObserver* observer, | 296 CreateSessionDescriptionObserver* observer, |
296 const MediaConstraintsInterface* constraints) { | 297 const MediaConstraintsInterface* constraints) { |
297 DCHECK(observer); | 298 DCHECK(observer); |
298 created_sessiondescription_.reset( | 299 created_sessiondescription_.reset( |
299 dependency_factory_->CreateSessionDescription("unknown", kDummyAnswer)); | 300 dependency_factory_->CreateSessionDescription("unknown", kDummyAnswer, |
| 301 NULL)); |
300 } | 302 } |
301 | 303 |
302 void MockPeerConnectionImpl::SetLocalDescriptionWorker( | 304 void MockPeerConnectionImpl::SetLocalDescriptionWorker( |
303 SetSessionDescriptionObserver* observer, | 305 SetSessionDescriptionObserver* observer, |
304 SessionDescriptionInterface* desc) { | 306 SessionDescriptionInterface* desc) { |
305 desc->ToString(&description_sdp_); | 307 desc->ToString(&description_sdp_); |
306 local_desc_.reset(desc); | 308 local_desc_.reset(desc); |
307 } | 309 } |
308 | 310 |
309 void MockPeerConnectionImpl::SetRemoteDescription( | 311 void MockPeerConnectionImpl::SetRemoteDescription( |
(...skipping 13 matching lines...) Expand all Loading... |
323 const IceCandidateInterface* candidate) { | 325 const IceCandidateInterface* candidate) { |
324 sdp_mid_ = candidate->sdp_mid(); | 326 sdp_mid_ = candidate->sdp_mid(); |
325 sdp_mline_index_ = candidate->sdp_mline_index(); | 327 sdp_mline_index_ = candidate->sdp_mline_index(); |
326 return candidate->ToString(&ice_sdp_); | 328 return candidate->ToString(&ice_sdp_); |
327 } | 329 } |
328 | 330 |
329 PeerConnectionInterface::IceState MockPeerConnectionImpl::ice_state() { | 331 PeerConnectionInterface::IceState MockPeerConnectionImpl::ice_state() { |
330 return ice_state_; | 332 return ice_state_; |
331 } | 333 } |
332 | 334 |
| 335 PeerConnectionInterface::IceConnectionState |
| 336 MockPeerConnectionImpl::ice_connection_state() { |
| 337 NOTIMPLEMENTED(); |
| 338 return PeerConnectionInterface::kIceConnectionNew; |
| 339 } |
| 340 |
| 341 PeerConnectionInterface::IceGatheringState |
| 342 MockPeerConnectionImpl::ice_gathering_state() { |
| 343 NOTIMPLEMENTED(); |
| 344 return PeerConnectionInterface::kIceGatheringNew; |
| 345 } |
| 346 |
333 } // namespace content | 347 } // namespace content |
OLD | NEW |