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

Side by Side Diff: webkit/blob/blob_url_request_job_factory.h

Issue 7036004: Remove more URLRequest::RegisterProtocolFactory calls. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: oops Created 9 years, 7 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 WEBKIT_BLOB_BLOB_URL_REQUEST_JOB_FACTORY_H_
6 #define WEBKIT_BLOB_BLOB_URL_REQUEST_JOB_FACTORY_H_
7
8 #include "base/compiler_specific.h"
9 #include "base/memory/ref_counted.h"
10 #include "net/url_request/url_request_job_factory.h"
11
12 namespace base {
13 class MessageLoopProxy;
14 } // namespace base
15
16 namespace net {
17 class URLRequest;
18 } // namespace net
19
20 namespace webkit_blob {
21
22 class BlobData;
23 class BlobStorageController;
24
25 class BlobProtocolHandler
26 : public net::URLRequestJobFactory::ProtocolHandler {
27 public:
28 // |controller|'s lifetime should exceed the lifetime of the ProtocolHandler.
29 explicit BlobProtocolHandler(
30 BlobStorageController* blob_storage_controller,
31 base::MessageLoopProxy* loop_proxy);
michaeln 2011/05/18 01:13:11 can u name this such that it indicates that it's t
willchan no longer on Chromium 2011/05/18 16:17:01 Done.
32 virtual ~BlobProtocolHandler();
33
34 virtual net::URLRequestJob* MaybeCreateJob(
35 net::URLRequest* request) const OVERRIDE;
36
37 private:
38 virtual scoped_refptr<BlobData> LookupBlobData(
39 net::URLRequest* request) const;
40
41 // No scoped_refptr because |blob_storage_controller_| is owned by the
42 // ProfileIOData, which also owns this ProtocolHandler.
43 BlobStorageController* const blob_storage_controller_;
44 const scoped_refptr<base::MessageLoopProxy> loop_proxy_;
45
46 DISALLOW_COPY_AND_ASSIGN(BlobProtocolHandler);
47 };
48
49 } // namespace webkit_blob
50
51 #endif // WEBKIT_BLOB_BLOB_URL_REQUEST_JOB_FACTORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698