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

Side by Side Diff: webrtc/api/peerconnectioninterface.h

Issue 1748403002: Move RtcEventLog object from inside VoiceEngine to Call. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Processed review comments and rebased. Created 4 years, 9 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 /* 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 439 matching lines...) Expand 10 before | Expand all | Expand 10 after
450 // Returns the current SignalingState. 450 // Returns the current SignalingState.
451 virtual SignalingState signaling_state() = 0; 451 virtual SignalingState signaling_state() = 0;
452 452
453 // TODO(bemasc): Remove ice_state when callers are changed to 453 // TODO(bemasc): Remove ice_state when callers are changed to
454 // IceConnection/GatheringState. 454 // IceConnection/GatheringState.
455 // Returns the current IceState. 455 // Returns the current IceState.
456 virtual IceState ice_state() = 0; 456 virtual IceState ice_state() = 0;
457 virtual IceConnectionState ice_connection_state() = 0; 457 virtual IceConnectionState ice_connection_state() = 0;
458 virtual IceGatheringState ice_gathering_state() = 0; 458 virtual IceGatheringState ice_gathering_state() = 0;
459 459
460 // Starts RtcEventLog using existing file. Takes ownership of |file| and
461 // passes it on to Call, which will take the ownership. If the
462 // operation fails the file will be closed. The logging will stop
463 // automatically after 10 minutes have passed, or when the StopRtcEventLog
464 // function is called.
465 virtual bool StartRtcEventLog(rtc::PlatformFile file,
466 int64_t max_size_bytes) = 0;
467
468 // Stops logging the RtcEventLog.
469 virtual void StopRtcEventLog() = 0;
470
460 // Terminates all media and closes the transport. 471 // Terminates all media and closes the transport.
461 virtual void Close() = 0; 472 virtual void Close() = 0;
462 473
463 protected: 474 protected:
464 // Dtor protected as objects shouldn't be deleted via this interface. 475 // Dtor protected as objects shouldn't be deleted via this interface.
465 ~PeerConnectionInterface() {} 476 ~PeerConnectionInterface() {}
466 }; 477 };
467 478
468 // PeerConnection callback interface. Application should implement these 479 // PeerConnection callback interface. Application should implement these
469 // methods. 480 // methods.
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
603 // the ownerhip. If the operation fails, the file will be closed. 614 // the ownerhip. If the operation fails, the file will be closed.
604 // A maximum file size in bytes can be specified. When the file size limit is 615 // A maximum file size in bytes can be specified. When the file size limit is
605 // reached, logging is stopped automatically. If max_size_bytes is set to a 616 // reached, logging is stopped automatically. If max_size_bytes is set to a
606 // value <= 0, no limit will be used, and logging will continue until the 617 // value <= 0, no limit will be used, and logging will continue until the
607 // StopAecDump function is called. 618 // StopAecDump function is called.
608 virtual bool StartAecDump(rtc::PlatformFile file, int64_t max_size_bytes) = 0; 619 virtual bool StartAecDump(rtc::PlatformFile file, int64_t max_size_bytes) = 0;
609 620
610 // Stops logging the AEC dump. 621 // Stops logging the AEC dump.
611 virtual void StopAecDump() = 0; 622 virtual void StopAecDump() = 0;
612 623
613 // Starts RtcEventLog using existing file. Takes ownership of |file| and 624 // This function is deprecated and will be removed when Chrome is updated to
614 // passes it on to VoiceEngine, which will take the ownership. If the 625 // use the equivalent function on PeerConnectionInterface.
615 // operation fails the file will be closed. The logging will stop 626 // TODO(ivoc) Remove after Chrome is updated.
616 // automatically after 10 minutes have passed, or when the StopRtcEventLog
617 // function is called.
618 // This function as well as the StopRtcEventLog don't really belong on this
619 // interface, this is a temporary solution until we move the logging object
620 // from inside voice engine to webrtc::Call, which will happen when the VoE
621 // restructuring effort is further along.
622 // TODO(ivoc): Move this into being:
623 // PeerConnection => MediaController => webrtc::Call.
624 virtual bool StartRtcEventLog(rtc::PlatformFile file) = 0; 627 virtual bool StartRtcEventLog(rtc::PlatformFile file) = 0;
625 628
626 // Stops logging the RtcEventLog. 629 // This function is deprecated and will be removed when Chrome is updated to
630 // use the equivalent function on PeerConnectionInterface.
631 // TODO(ivoc) Remove after Chrome is updated.
627 virtual void StopRtcEventLog() = 0; 632 virtual void StopRtcEventLog() = 0;
628 633
629 protected: 634 protected:
630 // Dtor and ctor protected as objects shouldn't be created or deleted via 635 // Dtor and ctor protected as objects shouldn't be created or deleted via
631 // this interface. 636 // this interface.
632 PeerConnectionFactoryInterface() {} 637 PeerConnectionFactoryInterface() {}
633 ~PeerConnectionFactoryInterface() {} // NOLINT 638 ~PeerConnectionFactoryInterface() {} // NOLINT
634 }; 639 };
635 640
636 // Create a new instance of PeerConnectionFactoryInterface. 641 // Create a new instance of PeerConnectionFactoryInterface.
637 rtc::scoped_refptr<PeerConnectionFactoryInterface> 642 rtc::scoped_refptr<PeerConnectionFactoryInterface>
638 CreatePeerConnectionFactory(); 643 CreatePeerConnectionFactory();
639 644
640 // Create a new instance of PeerConnectionFactoryInterface. 645 // Create a new instance of PeerConnectionFactoryInterface.
641 // Ownership of |factory|, |default_adm|, and optionally |encoder_factory| and 646 // Ownership of |factory|, |default_adm|, and optionally |encoder_factory| and
642 // |decoder_factory| transferred to the returned factory. 647 // |decoder_factory| transferred to the returned factory.
643 rtc::scoped_refptr<PeerConnectionFactoryInterface> 648 rtc::scoped_refptr<PeerConnectionFactoryInterface>
644 CreatePeerConnectionFactory( 649 CreatePeerConnectionFactory(
645 rtc::Thread* worker_thread, 650 rtc::Thread* worker_thread,
646 rtc::Thread* signaling_thread, 651 rtc::Thread* signaling_thread,
647 AudioDeviceModule* default_adm, 652 AudioDeviceModule* default_adm,
648 cricket::WebRtcVideoEncoderFactory* encoder_factory, 653 cricket::WebRtcVideoEncoderFactory* encoder_factory,
649 cricket::WebRtcVideoDecoderFactory* decoder_factory); 654 cricket::WebRtcVideoDecoderFactory* decoder_factory);
650 655
651 } // namespace webrtc 656 } // namespace webrtc
652 657
653 #endif // WEBRTC_API_PEERCONNECTIONINTERFACE_H_ 658 #endif // WEBRTC_API_PEERCONNECTIONINTERFACE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698