summaryrefslogtreecommitdiffstats
path: root/net/tools/fetch/http_session.h
diff options
context:
space:
mode:
authormbelshe@google.com <mbelshe@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-06 00:17:50 +0000
committermbelshe@google.com <mbelshe@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-06 00:17:50 +0000
commitacc9a6def1c4c7d8b54149667e0c476d0c85a8f4 (patch)
tree2028d25f0ea02000d572de224e91bc5201510baa /net/tools/fetch/http_session.h
parent914b40352efbf491c6bc98e624ad9cf00c7d9b79 (diff)
downloadchromium_src-acc9a6def1c4c7d8b54149667e0c476d0c85a8f4.zip
chromium_src-acc9a6def1c4c7d8b54149667e0c476d0c85a8f4.tar.gz
chromium_src-acc9a6def1c4c7d8b54149667e0c476d0c85a8f4.tar.bz2
A utility driver for doing client/server HTTP transaction
tests. This is an initial codebase - there is a lot of work to do. But I wanted to get an initial version checked in. http://crbug.com/6754 Review URL: http://codereview.chromium.org/99333 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15360 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/tools/fetch/http_session.h')
-rw-r--r--net/tools/fetch/http_session.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/net/tools/fetch/http_session.h b/net/tools/fetch/http_session.h
new file mode 100644
index 0000000..2289b30
--- /dev/null
+++ b/net/tools/fetch/http_session.h
@@ -0,0 +1,27 @@
+// Copyright (c) 2009 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 NET_BASE_TOOLS_HTTP_SESSION_H_
+#define NET_BASE_TOOLS_HTTP_SESSION_H_
+
+#include "base/basictypes.h"
+#include "net/http/http_request_info.h"
+#include "net/tools/fetch/http_listen_socket.h"
+
+// An HttpSession encapsulates a server-side HTTP listen socket.
+class HttpSession : HttpListenSocket::Delegate {
+public:
+ HttpSession(const std::string& ip, int port);
+ virtual ~HttpSession();
+
+ virtual void OnRequest(HttpListenSocket* connection,
+ HttpServerRequestInfo* info);
+
+private:
+ scoped_ptr<HttpListenSocket> socket_;
+ DISALLOW_EVIL_CONSTRUCTORS(HttpSession);
+};
+
+#endif // NET_BASE_TOOLS_HTTP_SESSION_H_
+