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_FILEAPI_FILE_SYSTEM_URL_REQUEST_JOB_H_ | 5 #ifndef WEBKIT_FILEAPI_FILE_SYSTEM_URL_REQUEST_JOB_H_ |
6 #define WEBKIT_FILEAPI_FILE_SYSTEM_URL_REQUEST_JOB_H_ | 6 #define WEBKIT_FILEAPI_FILE_SYSTEM_URL_REQUEST_JOB_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "base/memory/ref_counted.h" | 11 #include "base/memory/ref_counted.h" |
12 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
13 #include "base/memory/weak_ptr.h" | 13 #include "base/memory/weak_ptr.h" |
14 #include "base/platform_file.h" | 14 #include "base/platform_file.h" |
15 #include "net/http/http_byte_range.h" | 15 #include "net/http/http_byte_range.h" |
16 #include "net/url_request/url_request_job.h" | 16 #include "net/url_request/url_request_job.h" |
| 17 #include "webkit/fileapi/fileapi_export.h" |
17 | 18 |
18 class GURL; | 19 class GURL; |
19 class FilePath; | 20 class FilePath; |
20 | 21 |
21 namespace webkit_blob { | 22 namespace webkit_blob { |
22 class FileReader; | 23 class FileReader; |
23 } | 24 } |
24 | 25 |
25 namespace fileapi { | 26 namespace fileapi { |
26 class FileSystemContext; | 27 class FileSystemContext; |
27 | 28 |
28 // A request job that handles reading filesystem: URLs | 29 // A request job that handles reading filesystem: URLs |
29 class FileSystemURLRequestJob : public net::URLRequestJob { | 30 class FILEAPI_EXPORT_PRIVATE FileSystemURLRequestJob |
| 31 : public net::URLRequestJob { |
30 public: | 32 public: |
31 FileSystemURLRequestJob( | 33 FileSystemURLRequestJob( |
32 net::URLRequest* request, | 34 net::URLRequest* request, |
33 FileSystemContext* file_system_context); | 35 FileSystemContext* file_system_context); |
34 | 36 |
35 // URLRequestJob methods: | 37 // URLRequestJob methods: |
36 virtual void Start() OVERRIDE; | 38 virtual void Start() OVERRIDE; |
37 virtual void Kill() OVERRIDE; | 39 virtual void Kill() OVERRIDE; |
38 virtual bool ReadRawData(net::IOBuffer* buf, | 40 virtual bool ReadRawData(net::IOBuffer* buf, |
39 int buf_size, | 41 int buf_size, |
(...skipping 28 matching lines...) Expand all Loading... |
68 scoped_ptr<net::HttpResponseInfo> response_info_; | 70 scoped_ptr<net::HttpResponseInfo> response_info_; |
69 int64 remaining_bytes_; | 71 int64 remaining_bytes_; |
70 net::HttpByteRange byte_range_; | 72 net::HttpByteRange byte_range_; |
71 | 73 |
72 DISALLOW_COPY_AND_ASSIGN(FileSystemURLRequestJob); | 74 DISALLOW_COPY_AND_ASSIGN(FileSystemURLRequestJob); |
73 }; | 75 }; |
74 | 76 |
75 } // namespace fileapi | 77 } // namespace fileapi |
76 | 78 |
77 #endif // WEBKIT_FILEAPI_FILE_SYSTEM_URL_REQUEST_JOB_H_ | 79 #endif // WEBKIT_FILEAPI_FILE_SYSTEM_URL_REQUEST_JOB_H_ |
OLD | NEW |