summaryrefslogtreecommitdiffstats
path: root/jingle/glue/resolving_client_socket_factory.h
diff options
context:
space:
mode:
Diffstat (limited to 'jingle/glue/resolving_client_socket_factory.h')
-rw-r--r--jingle/glue/resolving_client_socket_factory.h36
1 files changed, 36 insertions, 0 deletions
diff --git a/jingle/glue/resolving_client_socket_factory.h b/jingle/glue/resolving_client_socket_factory.h
new file mode 100644
index 0000000..5be8bc8
--- /dev/null
+++ b/jingle/glue/resolving_client_socket_factory.h
@@ -0,0 +1,36 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef JINGLE_GLUE_RESOLVING_CLIENT_SOCKET_FACTORY_H_
+#define JINGLE_GLUE_RESOLVING_CLIENT_SOCKET_FACTORY_H_
+
+
+namespace net {
+class ClientSocketHandle;
+class HostPortPair;
+class SSLClientSocket;
+class StreamSocket;
+} // namespace net
+
+// TODO(sanjeevr): Move this to net/
+
+namespace jingle_glue {
+
+// Interface for a ClientSocketFactory that creates ClientSockets that can
+// resolve host names and tunnel through proxies.
+class ResolvingClientSocketFactory {
+ public:
+ virtual ~ResolvingClientSocketFactory() { }
+ // Method to create a transport socket using a HostPortPair.
+ virtual net::StreamSocket* CreateTransportClientSocket(
+ const net::HostPortPair& host_and_port) = 0;
+
+ virtual net::SSLClientSocket* CreateSSLClientSocket(
+ net::ClientSocketHandle* transport_socket,
+ const net::HostPortPair& host_and_port) = 0;
+};
+
+} // namespace jingle_glue
+
+#endif // JINGLE_GLUE_RESOLVING_CLIENT_SOCKET_FACTORY_H_