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

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

Issue 8311010: base::Bind: Convert FileUtilProxy::CreateOrOpenCallback. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 2 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
« no previous file with comments | « chrome/browser/nacl_host/nacl_process_host.cc ('k') | webkit/blob/blob_url_request_job.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 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 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_BLOB_BLOB_URL_REQUEST_JOB_H_ 5 #ifndef WEBKIT_BLOB_BLOB_URL_REQUEST_JOB_H_
6 #define WEBKIT_BLOB_BLOB_URL_REQUEST_JOB_H_ 6 #define WEBKIT_BLOB_BLOB_URL_REQUEST_JOB_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/scoped_callback_factory.h" 9 #include "base/memory/scoped_callback_factory.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
11 #include "base/memory/weak_ptr.h"
11 #include "base/platform_file.h" 12 #include "base/platform_file.h"
12 #include "base/task.h" 13 #include "base/task.h"
13 #include "net/http/http_byte_range.h" 14 #include "net/http/http_byte_range.h"
14 #include "net/url_request/url_request_job.h" 15 #include "net/url_request/url_request_job.h"
15 #include "webkit/blob/blob_data.h" 16 #include "webkit/blob/blob_data.h"
16 17
17 namespace base { 18 namespace base {
18 class MessageLoopProxy; 19 class MessageLoopProxy;
19 struct PlatformFileInfo; 20 struct PlatformFileInfo;
20 } 21 }
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 63
63 void DidStart(); 64 void DidStart();
64 void DidResolve(base::PlatformFileError rv, 65 void DidResolve(base::PlatformFileError rv,
65 const base::PlatformFileInfo& file_info); 66 const base::PlatformFileInfo& file_info);
66 void DidOpen(base::PlatformFileError rv, 67 void DidOpen(base::PlatformFileError rv,
67 base::PassPlatformFile file, 68 base::PassPlatformFile file,
68 bool created); 69 bool created);
69 void DidRead(int result); 70 void DidRead(int result);
70 71
71 base::ScopedCallbackFactory<BlobURLRequestJob> callback_factory_; 72 base::ScopedCallbackFactory<BlobURLRequestJob> callback_factory_;
73 base::WeakPtrFactory<BlobURLRequestJob> weak_factory_;
72 scoped_refptr<BlobData> blob_data_; 74 scoped_refptr<BlobData> blob_data_;
73 scoped_refptr<base::MessageLoopProxy> file_thread_proxy_; 75 scoped_refptr<base::MessageLoopProxy> file_thread_proxy_;
74 std::vector<int64> item_length_list_; 76 std::vector<int64> item_length_list_;
75 scoped_ptr<net::FileStream> stream_; 77 scoped_ptr<net::FileStream> stream_;
76 size_t item_index_; 78 size_t item_index_;
77 int64 total_size_; 79 int64 total_size_;
78 int64 current_item_offset_; 80 int64 current_item_offset_;
79 int64 remaining_bytes_; 81 int64 remaining_bytes_;
80 scoped_refptr<net::IOBuffer> read_buf_; 82 scoped_refptr<net::IOBuffer> read_buf_;
81 int read_buf_offset_; 83 int read_buf_offset_;
82 int read_buf_size_; 84 int read_buf_size_;
83 int read_buf_remaining_bytes_; 85 int read_buf_remaining_bytes_;
84 int bytes_to_read_; 86 int bytes_to_read_;
85 bool error_; 87 bool error_;
86 bool headers_set_; 88 bool headers_set_;
87 bool byte_range_set_; 89 bool byte_range_set_;
88 net::HttpByteRange byte_range_; 90 net::HttpByteRange byte_range_;
89 scoped_ptr<net::HttpResponseInfo> response_info_; 91 scoped_ptr<net::HttpResponseInfo> response_info_;
90 ScopedRunnableMethodFactory<BlobURLRequestJob> method_factory_; 92 ScopedRunnableMethodFactory<BlobURLRequestJob> method_factory_;
91 93
92 DISALLOW_COPY_AND_ASSIGN(BlobURLRequestJob); 94 DISALLOW_COPY_AND_ASSIGN(BlobURLRequestJob);
93 }; 95 };
94 96
95 } // namespace webkit_blob 97 } // namespace webkit_blob
96 98
97 #endif // WEBKIT_BLOB_BLOB_URL_REQUEST_JOB_H_ 99 #endif // WEBKIT_BLOB_BLOB_URL_REQUEST_JOB_H_
OLDNEW
« no previous file with comments | « chrome/browser/nacl_host/nacl_process_host.cc ('k') | webkit/blob/blob_url_request_job.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698