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

Unified Diff: chrome/browser/net/connect_interceptor.h

Issue 11293252: Change Interceptors into URLRequestJobFactory::ProtocolHandlers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: sync Created 8 years 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 | « chrome/browser/net/chrome_network_delegate.cc ('k') | chrome/browser/net/connect_interceptor.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/net/connect_interceptor.h
diff --git a/chrome/browser/net/connect_interceptor.h b/chrome/browser/net/connect_interceptor.h
index afc27af9e01c16d1533c9974dae5053ee9b7874c..3372ad81e714bdbd0a2508f1fe5550d675edbd47 100644
--- a/chrome/browser/net/connect_interceptor.h
+++ b/chrome/browser/net/connect_interceptor.h
@@ -7,8 +7,14 @@
#include "base/containers/mru_cache.h"
#include "base/gtest_prod_util.h"
+#include "base/memory/scoped_ptr.h"
#include "base/time.h"
-#include "net/url_request/url_request_job_factory.h"
+
+class GURL;
+
+namespace net {
+class URLRequest;
+}
namespace chrome_browser_net {
@@ -17,26 +23,15 @@ class Predictor;
//------------------------------------------------------------------------------
// An interceptor to monitor URLRequests so that we can do speculative DNS
// resolution and/or speculative TCP preconnections.
-class ConnectInterceptor : public net::URLRequestJobFactory::Interceptor {
+class ConnectInterceptor {
public:
// Construction includes registration as an URL.
explicit ConnectInterceptor(Predictor* predictor);
// Destruction includes unregistering.
virtual ~ConnectInterceptor();
- protected:
- // Overridden from net::URLRequest::Interceptor:
// Learn about referrers, and optionally preconnect based on history.
- virtual net::URLRequestJob* MaybeIntercept(
- net::URLRequest* request,
- net::NetworkDelegate* network_delegate) const OVERRIDE;
- virtual net::URLRequestJob* MaybeInterceptResponse(
- net::URLRequest* request,
- net::NetworkDelegate* network_delegate) const OVERRIDE;
- virtual net::URLRequestJob* MaybeInterceptRedirect(
- const GURL& location,
- net::URLRequest* request,
- net::NetworkDelegate* network_delegate) const OVERRIDE;
+ void WitnessURLRequest(net::URLRequest* request) const;
private:
// Provide access to local class TimedCache for testing.
« no previous file with comments | « chrome/browser/net/chrome_network_delegate.cc ('k') | chrome/browser/net/connect_interceptor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698