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

Unified Diff: talk/app/webrtc/peerconnectioninterface.h

Issue 1176383004: DtlsIdentityStore[Interface/Impl] updated, DtlsIdentityService to be removed (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Merge w master AFTER the landing of 1268363002. "CreatePC(service,store)" using store instead of service. Created 5 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « talk/app/webrtc/peerconnectionfactoryproxy.h ('k') | talk/app/webrtc/peerconnectioninterface_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: talk/app/webrtc/peerconnectioninterface.h
diff --git a/talk/app/webrtc/peerconnectioninterface.h b/talk/app/webrtc/peerconnectioninterface.h
index 946b1253c99bfca3ce1bd508a0973f6f437e83d6..5268187e8f31c022ef2d1d42f9c617ded6614ef6 100644
--- a/talk/app/webrtc/peerconnectioninterface.h
+++ b/talk/app/webrtc/peerconnectioninterface.h
@@ -74,6 +74,7 @@
#include "talk/app/webrtc/datachannelinterface.h"
#include "talk/app/webrtc/dtlsidentitystore.h"
#include "talk/app/webrtc/dtmfsenderinterface.h"
+#include "talk/app/webrtc/dtlsidentitystore.h"
#include "talk/app/webrtc/jsep.h"
#include "talk/app/webrtc/mediastreaminterface.h"
#include "talk/app/webrtc/statstypes.h"
@@ -467,6 +468,7 @@ class PortAllocatorFactoryInterface : public rtc::RefCountInterface {
~PortAllocatorFactoryInterface() {}
};
+// TODO(hbos): Remove once cr/1176383004 lands.
class DTLSIdentityServiceInterface {
public:
// Asynchronously request a DTLS identity, including a self-signed certificate
@@ -535,6 +537,7 @@ class PeerConnectionFactoryInterface : public rtc::RefCountInterface {
// TODO(hbos): Temporary CreatePeerConnection function while we transition
// from DTLSIdentityServiceInterface to DtlsIdentityStoreInterface.
+ // This method takes the ownership of |dtls_identity_service|.
rtc::scoped_refptr<PeerConnectionInterface>
CreatePeerConnection(
const PeerConnectionInterface::RTCConfiguration& configuration,
@@ -543,21 +546,23 @@ class PeerConnectionFactoryInterface : public rtc::RefCountInterface {
DTLSIdentityServiceInterface* dtls_identity_service,
rtc::scoped_ptr<DtlsIdentityStoreInterface> dtls_identity_store,
PeerConnectionObserver* observer) {
+ if (dtls_identity_service) {
+ // Store used instead of service, our ownership responsibility to delete.
+ delete dtls_identity_service;
+ }
return CreatePeerConnection(configuration, constraints, allocator_factory,
- dtls_identity_service, observer);
+ dtls_identity_store.Pass(), observer);
}
- // This method takes the ownership of |dtls_identity_service|.
virtual rtc::scoped_refptr<PeerConnectionInterface>
CreatePeerConnection(
const PeerConnectionInterface::RTCConfiguration& configuration,
const MediaConstraintsInterface* constraints,
PortAllocatorFactoryInterface* allocator_factory,
- DTLSIdentityServiceInterface* dtls_identity_service,
+ rtc::scoped_ptr<DtlsIdentityStoreInterface> dtls_identity_store,
PeerConnectionObserver* observer) = 0;
- // TODO(mallinath) : Remove below versions after clients are updated
- // to above method.
+ // TODO(hbos): Remove below version after clients are updated to above method.
// In latest W3C WebRTC draft, PC constructor will take RTCConfiguration,
// and not IceServers. RTCConfiguration is made up of ice servers and
// ice transport type.
@@ -567,12 +572,12 @@ class PeerConnectionFactoryInterface : public rtc::RefCountInterface {
const PeerConnectionInterface::IceServers& servers,
const MediaConstraintsInterface* constraints,
PortAllocatorFactoryInterface* allocator_factory,
- DTLSIdentityServiceInterface* dtls_identity_service,
+ rtc::scoped_ptr<DtlsIdentityStoreInterface> dtls_identity_store,
PeerConnectionObserver* observer) {
PeerConnectionInterface::RTCConfiguration rtc_config;
rtc_config.servers = servers;
return CreatePeerConnection(rtc_config, constraints, allocator_factory,
- dtls_identity_service, observer);
+ dtls_identity_store.Pass(), observer);
}
virtual rtc::scoped_refptr<MediaStreamInterface>
« no previous file with comments | « talk/app/webrtc/peerconnectionfactoryproxy.h ('k') | talk/app/webrtc/peerconnectioninterface_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698