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

Side by Side Diff: net/url_request/url_request_job_factory_impl.h

Issue 10836248: Turned job_factory into a pure virtual class (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed nits Created 8 years, 3 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef NET_URL_REQUEST_URL_REQUEST_JOB_FACTORY_IMPL_H_
6 #define NET_URL_REQUEST_URL_REQUEST_JOB_FACTORY_IMPL_H_
7
8 #include <map>
9 #include <vector>
10 #include "base/basictypes.h"
11 #include "net/base/net_export.h"
12 #include "net/url_request/url_request_job_factory.h"
13
14 namespace net {
15
16 class NET_EXPORT URLRequestJobFactoryImpl : public URLRequestJobFactory {
17 public:
18 URLRequestJobFactoryImpl();
19 virtual ~URLRequestJobFactoryImpl();
20
21 // URLRequestJobFactory implementation
22
erikwright (departed) 2012/08/22 20:57:35 nit: remove vertical whitespace.
shalev 2012/08/23 15:15:46 Done.
23 virtual bool SetProtocolHandler(const std::string& scheme,
24 ProtocolHandler* protocol_handler) OVERRIDE;
25
26 virtual void AddInterceptor(Interceptor* interceptor);
27
28 virtual URLRequestJob* MaybeCreateJobWithInterceptor(
29 URLRequest* request) const OVERRIDE;
30
31 virtual URLRequestJob* MaybeCreateJobWithProtocolHandler(
32 const std::string& scheme, URLRequest* request) const OVERRIDE;
33
34 virtual URLRequestJob* MaybeInterceptRedirect(
35 const GURL& location, URLRequest* request) const OVERRIDE;
36
37 virtual URLRequestJob* MaybeInterceptResponse(
38 URLRequest* request) const OVERRIDE;
39
40 virtual bool IsHandledProtocol(const std::string& scheme) const OVERRIDE;
41
42 virtual bool IsHandledURL(const GURL& url) const OVERRIDE;
43
44 private:
45 typedef std::map<std::string, ProtocolHandler*> ProtocolHandlerMap;
46 typedef std::vector<Interceptor*> InterceptorList;
47
48 ProtocolHandlerMap protocol_handler_map_;
49 InterceptorList interceptors_;
50
51 DISALLOW_COPY_AND_ASSIGN(URLRequestJobFactoryImpl);
52 };
53
54 } // namespace net
55
56 #endif // NET_URL_REQUEST_URL_REQUEST_JOB_FACTORY_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698