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 421 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
432 return false; | 432 return false; |
433 } | 433 } |
434 // Provides a remote candidate to the ICE Agent. | 434 // Provides a remote candidate to the ICE Agent. |
435 // A copy of the |candidate| will be created and added to the remote | 435 // A copy of the |candidate| will be created and added to the remote |
436 // description. So the caller of this method still has the ownership of the | 436 // description. So the caller of this method still has the ownership of the |
437 // |candidate|. | 437 // |candidate|. |
438 // TODO(ronghuawu): Consider to change this so that the AddIceCandidate will | 438 // TODO(ronghuawu): Consider to change this so that the AddIceCandidate will |
439 // take the ownership of the |candidate|. | 439 // take the ownership of the |candidate|. |
440 virtual bool AddIceCandidate(const IceCandidateInterface* candidate) = 0; | 440 virtual bool AddIceCandidate(const IceCandidateInterface* candidate) = 0; |
441 | 441 |
| 442 // Removes a group of remote candidates from the ICE agent. |
| 443 virtual bool RemoveIceCandidates(const cricket::Candidates& candidates) { |
| 444 return false; |
| 445 } |
| 446 |
442 virtual void RegisterUMAObserver(UMAObserver* observer) = 0; | 447 virtual void RegisterUMAObserver(UMAObserver* observer) = 0; |
443 | 448 |
444 // Returns the current SignalingState. | 449 // Returns the current SignalingState. |
445 virtual SignalingState signaling_state() = 0; | 450 virtual SignalingState signaling_state() = 0; |
446 | 451 |
447 // TODO(bemasc): Remove ice_state when callers are changed to | 452 // TODO(bemasc): Remove ice_state when callers are changed to |
448 // IceConnection/GatheringState. | 453 // IceConnection/GatheringState. |
449 // Returns the current IceState. | 454 // Returns the current IceState. |
450 virtual IceState ice_state() = 0; | 455 virtual IceState ice_state() = 0; |
451 virtual IceConnectionState ice_connection_state() = 0; | 456 virtual IceConnectionState ice_connection_state() = 0; |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
488 virtual void OnIceConnectionChange( | 493 virtual void OnIceConnectionChange( |
489 PeerConnectionInterface::IceConnectionState new_state) = 0; | 494 PeerConnectionInterface::IceConnectionState new_state) = 0; |
490 | 495 |
491 // Called any time the IceGatheringState changes | 496 // Called any time the IceGatheringState changes |
492 virtual void OnIceGatheringChange( | 497 virtual void OnIceGatheringChange( |
493 PeerConnectionInterface::IceGatheringState new_state) = 0; | 498 PeerConnectionInterface::IceGatheringState new_state) = 0; |
494 | 499 |
495 // New Ice candidate have been found. | 500 // New Ice candidate have been found. |
496 virtual void OnIceCandidate(const IceCandidateInterface* candidate) = 0; | 501 virtual void OnIceCandidate(const IceCandidateInterface* candidate) = 0; |
497 | 502 |
| 503 // Ice candidates have been removed. |
| 504 // TODO(honghaiz): Make this a pure virtual method when all its subclasses |
| 505 // implement it. |
| 506 virtual void OnIceCandidatesRemoved(const cricket::Candidates& candidates) {} |
| 507 |
498 // Called when the ICE connection receiving status changes. | 508 // Called when the ICE connection receiving status changes. |
499 virtual void OnIceConnectionReceivingChange(bool receiving) {} | 509 virtual void OnIceConnectionReceivingChange(bool receiving) {} |
500 | 510 |
501 protected: | 511 protected: |
502 // Dtor protected as objects shouldn't be deleted via this interface. | 512 // Dtor protected as objects shouldn't be deleted via this interface. |
503 ~PeerConnectionObserver() {} | 513 ~PeerConnectionObserver() {} |
504 }; | 514 }; |
505 | 515 |
506 // PeerConnectionFactoryInterface is the factory interface use for creating | 516 // PeerConnectionFactoryInterface is the factory interface use for creating |
507 // PeerConnection, MediaStream and media tracks. | 517 // PeerConnection, MediaStream and media tracks. |
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
632 CreatePeerConnectionFactory( | 642 CreatePeerConnectionFactory( |
633 rtc::Thread* worker_thread, | 643 rtc::Thread* worker_thread, |
634 rtc::Thread* signaling_thread, | 644 rtc::Thread* signaling_thread, |
635 AudioDeviceModule* default_adm, | 645 AudioDeviceModule* default_adm, |
636 cricket::WebRtcVideoEncoderFactory* encoder_factory, | 646 cricket::WebRtcVideoEncoderFactory* encoder_factory, |
637 cricket::WebRtcVideoDecoderFactory* decoder_factory); | 647 cricket::WebRtcVideoDecoderFactory* decoder_factory); |
638 | 648 |
639 } // namespace webrtc | 649 } // namespace webrtc |
640 | 650 |
641 #endif // WEBRTC_API_PEERCONNECTIONINTERFACE_H_ | 651 #endif // WEBRTC_API_PEERCONNECTIONINTERFACE_H_ |
OLD | NEW |