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 CONTENT_BROWSER_RENDERER_HOST_SYNC_RESOURCE_HANDLER_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_SYNC_RESOURCE_HANDLER_H_ |
6 #define CONTENT_BROWSER_RENDERER_HOST_SYNC_RESOURCE_HANDLER_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_SYNC_RESOURCE_HANDLER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 23 matching lines...) Expand all Loading... |
34 ResourceDispatcherHostImpl* resource_dispatcher_host); | 34 ResourceDispatcherHostImpl* resource_dispatcher_host); |
35 | 35 |
36 virtual bool OnUploadProgress(int request_id, | 36 virtual bool OnUploadProgress(int request_id, |
37 uint64 position, | 37 uint64 position, |
38 uint64 size) OVERRIDE; | 38 uint64 size) OVERRIDE; |
39 virtual bool OnRequestRedirected(int request_id, | 39 virtual bool OnRequestRedirected(int request_id, |
40 const GURL& new_url, | 40 const GURL& new_url, |
41 ResourceResponse* response, | 41 ResourceResponse* response, |
42 bool* defer) OVERRIDE; | 42 bool* defer) OVERRIDE; |
43 virtual bool OnResponseStarted(int request_id, | 43 virtual bool OnResponseStarted(int request_id, |
44 ResourceResponse* response) OVERRIDE; | 44 ResourceResponse* response, |
| 45 bool* defer) OVERRIDE; |
45 virtual bool OnWillStart(int request_id, | 46 virtual bool OnWillStart(int request_id, |
46 const GURL& url, | 47 const GURL& url, |
47 bool* defer) OVERRIDE; | 48 bool* defer) OVERRIDE; |
48 virtual bool OnWillRead(int request_id, | 49 virtual bool OnWillRead(int request_id, |
49 net::IOBuffer** buf, | 50 net::IOBuffer** buf, |
50 int* buf_size, | 51 int* buf_size, |
51 int min_size) OVERRIDE; | 52 int min_size) OVERRIDE; |
52 virtual bool OnReadCompleted(int request_id, | 53 virtual bool OnReadCompleted(int request_id, |
53 int* bytes_read) OVERRIDE; | 54 int* bytes_read, |
| 55 bool* defer) OVERRIDE; |
54 virtual bool OnResponseCompleted(int request_id, | 56 virtual bool OnResponseCompleted(int request_id, |
55 const net::URLRequestStatus& status, | 57 const net::URLRequestStatus& status, |
56 const std::string& security_info) OVERRIDE; | 58 const std::string& security_info) OVERRIDE; |
57 virtual void OnRequestClosed() OVERRIDE; | 59 virtual void OnRequestClosed() OVERRIDE; |
58 | 60 |
59 private: | 61 private: |
60 enum { kReadBufSize = 3840 }; | 62 enum { kReadBufSize = 3840 }; |
61 | 63 |
62 virtual ~SyncResourceHandler(); | 64 virtual ~SyncResourceHandler(); |
63 | 65 |
64 scoped_refptr<net::IOBuffer> read_buffer_; | 66 scoped_refptr<net::IOBuffer> read_buffer_; |
65 | 67 |
66 SyncLoadResult result_; | 68 SyncLoadResult result_; |
67 scoped_refptr<ResourceMessageFilter> filter_; | 69 scoped_refptr<ResourceMessageFilter> filter_; |
68 IPC::Message* result_message_; | 70 IPC::Message* result_message_; |
69 ResourceDispatcherHostImpl* rdh_; | 71 ResourceDispatcherHostImpl* rdh_; |
70 }; | 72 }; |
71 | 73 |
72 } // namespace content | 74 } // namespace content |
73 | 75 |
74 #endif // CONTENT_BROWSER_RENDERER_HOST_SYNC_RESOURCE_HANDLER_H_ | 76 #endif // CONTENT_BROWSER_RENDERER_HOST_SYNC_RESOURCE_HANDLER_H_ |
OLD | NEW |