| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef WEBKIT_BROWSER_BLOB_BLOB_URL_REQUEST_JOB_H_ | 5 #ifndef WEBKIT_BROWSER_BLOB_BLOB_URL_REQUEST_JOB_H_ |
| 6 #define WEBKIT_BROWSER_BLOB_BLOB_URL_REQUEST_JOB_H_ | 6 #define WEBKIT_BROWSER_BLOB_BLOB_URL_REQUEST_JOB_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 | 9 |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 namespace storage { | 31 namespace storage { |
| 32 | 32 |
| 33 class FileStreamReader; | 33 class FileStreamReader; |
| 34 | 34 |
| 35 // A request job that handles reading blob URLs. | 35 // A request job that handles reading blob URLs. |
| 36 class STORAGE_EXPORT BlobURLRequestJob | 36 class STORAGE_EXPORT BlobURLRequestJob |
| 37 : public net::URLRequestJob { | 37 : public net::URLRequestJob { |
| 38 public: | 38 public: |
| 39 BlobURLRequestJob(net::URLRequest* request, | 39 BlobURLRequestJob(net::URLRequest* request, |
| 40 net::NetworkDelegate* network_delegate, | 40 net::NetworkDelegate* network_delegate, |
| 41 BlobData* blob_data, | 41 const scoped_refptr<BlobData>& blob_data, |
| 42 storage::FileSystemContext* file_system_context, | 42 storage::FileSystemContext* file_system_context, |
| 43 base::MessageLoopProxy* resolving_message_loop_proxy); | 43 base::MessageLoopProxy* resolving_message_loop_proxy); |
| 44 | 44 |
| 45 // net::URLRequestJob methods. | 45 // net::URLRequestJob methods. |
| 46 virtual void Start() OVERRIDE; | 46 virtual void Start() OVERRIDE; |
| 47 virtual void Kill() OVERRIDE; | 47 virtual void Kill() OVERRIDE; |
| 48 virtual bool ReadRawData(net::IOBuffer* buf, | 48 virtual bool ReadRawData(net::IOBuffer* buf, |
| 49 int buf_size, | 49 int buf_size, |
| 50 int* bytes_read) OVERRIDE; | 50 int* bytes_read) OVERRIDE; |
| 51 virtual bool GetMimeType(std::string* mime_type) const OVERRIDE; | 51 virtual bool GetMimeType(std::string* mime_type) const OVERRIDE; |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 scoped_ptr<net::HttpResponseInfo> response_info_; | 120 scoped_ptr<net::HttpResponseInfo> response_info_; |
| 121 | 121 |
| 122 base::WeakPtrFactory<BlobURLRequestJob> weak_factory_; | 122 base::WeakPtrFactory<BlobURLRequestJob> weak_factory_; |
| 123 | 123 |
| 124 DISALLOW_COPY_AND_ASSIGN(BlobURLRequestJob); | 124 DISALLOW_COPY_AND_ASSIGN(BlobURLRequestJob); |
| 125 }; | 125 }; |
| 126 | 126 |
| 127 } // namespace storage | 127 } // namespace storage |
| 128 | 128 |
| 129 #endif // WEBKIT_BROWSER_BLOB_BLOB_URL_REQUEST_JOB_H_ | 129 #endif // WEBKIT_BROWSER_BLOB_BLOB_URL_REQUEST_JOB_H_ |
| OLD | NEW |