OLD | NEW |
1 // Copyright (c) 2006-2008 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 CHROME_BROWSER_RENDERER_HOST_SYNC_RESOURCE_HANDLER_H_ | 5 #ifndef CHROME_BROWSER_RENDERER_HOST_SYNC_RESOURCE_HANDLER_H_ |
6 #define CHROME_BROWSER_RENDERER_HOST_SYNC_RESOURCE_HANDLER_H_ | 6 #define CHROME_BROWSER_RENDERER_HOST_SYNC_RESOURCE_HANDLER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "chrome/browser/renderer_host/resource_handler.h" | 11 #include "chrome/browser/renderer_host/resource_handler.h" |
(...skipping 21 matching lines...) Expand all Loading... |
33 | 33 |
34 virtual bool OnUploadProgress(int request_id, uint64 position, uint64 size); | 34 virtual bool OnUploadProgress(int request_id, uint64 position, uint64 size); |
35 virtual bool OnRequestRedirected(int request_id, const GURL& new_url, | 35 virtual bool OnRequestRedirected(int request_id, const GURL& new_url, |
36 ResourceResponse* response, bool* defer); | 36 ResourceResponse* response, bool* defer); |
37 virtual bool OnResponseStarted(int request_id, ResourceResponse* response); | 37 virtual bool OnResponseStarted(int request_id, ResourceResponse* response); |
38 virtual bool OnWillStart(int request_id, const GURL& url, bool* defer); | 38 virtual bool OnWillStart(int request_id, const GURL& url, bool* defer); |
39 virtual bool OnWillRead(int request_id, net::IOBuffer** buf, int* buf_size, | 39 virtual bool OnWillRead(int request_id, net::IOBuffer** buf, int* buf_size, |
40 int min_size); | 40 int min_size); |
41 virtual bool OnReadCompleted(int request_id, int* bytes_read); | 41 virtual bool OnReadCompleted(int request_id, int* bytes_read); |
42 virtual bool OnResponseCompleted(int request_id, | 42 virtual bool OnResponseCompleted(int request_id, |
43 const URLRequestStatus& status, | 43 const net::URLRequestStatus& status, |
44 const std::string& security_info); | 44 const std::string& security_info); |
45 virtual void OnRequestClosed(); | 45 virtual void OnRequestClosed(); |
46 | 46 |
47 private: | 47 private: |
48 enum { kReadBufSize = 3840 }; | 48 enum { kReadBufSize = 3840 }; |
49 | 49 |
50 ~SyncResourceHandler(); | 50 ~SyncResourceHandler(); |
51 | 51 |
52 scoped_refptr<net::IOBuffer> read_buffer_; | 52 scoped_refptr<net::IOBuffer> read_buffer_; |
53 | 53 |
54 SyncLoadResult result_; | 54 SyncLoadResult result_; |
55 ResourceMessageFilter* filter_; | 55 ResourceMessageFilter* filter_; |
56 IPC::Message* result_message_; | 56 IPC::Message* result_message_; |
57 ResourceDispatcherHost* rdh_; | 57 ResourceDispatcherHost* rdh_; |
58 }; | 58 }; |
59 | 59 |
60 #endif // CHROME_BROWSER_RENDERER_HOST_SYNC_RESOURCE_HANDLER_H_ | 60 #endif // CHROME_BROWSER_RENDERER_HOST_SYNC_RESOURCE_HANDLER_H_ |
OLD | NEW |