OLD | NEW |
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 CONTENT_BROWSER_FILE_SYSTEM_FILE_SYSTEM_DISPATCHER_HOST_H_ | 5 #ifndef CONTENT_BROWSER_FILE_SYSTEM_FILE_SYSTEM_DISPATCHER_HOST_H_ |
6 #define CONTENT_BROWSER_FILE_SYSTEM_FILE_SYSTEM_DISPATCHER_HOST_H_ | 6 #define CONTENT_BROWSER_FILE_SYSTEM_FILE_SYSTEM_DISPATCHER_HOST_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 24 matching lines...) Expand all Loading... |
35 } // namespace net | 35 } // namespace net |
36 | 36 |
37 class FileSystemDispatcherHost : public BrowserMessageFilter { | 37 class FileSystemDispatcherHost : public BrowserMessageFilter { |
38 public: | 38 public: |
39 // Used by the renderer. | 39 // Used by the renderer. |
40 explicit FileSystemDispatcherHost( | 40 explicit FileSystemDispatcherHost( |
41 const content::ResourceContext* resource_context); | 41 const content::ResourceContext* resource_context); |
42 // Used by the worker, since it has the context handy already. | 42 // Used by the worker, since it has the context handy already. |
43 FileSystemDispatcherHost(net::URLRequestContext* request_context, | 43 FileSystemDispatcherHost(net::URLRequestContext* request_context, |
44 fileapi::FileSystemContext* file_system_context); | 44 fileapi::FileSystemContext* file_system_context); |
45 ~FileSystemDispatcherHost(); | 45 virtual ~FileSystemDispatcherHost(); |
46 | 46 |
47 // BrowserMessageFilter implementation. | 47 // BrowserMessageFilter implementation. |
48 virtual void OnChannelConnected(int32 peer_pid); | 48 virtual void OnChannelConnected(int32 peer_pid); |
49 virtual bool OnMessageReceived(const IPC::Message& message, | 49 virtual bool OnMessageReceived(const IPC::Message& message, |
50 bool* message_was_ok); | 50 bool* message_was_ok); |
51 | 51 |
52 void UnregisterOperation(int request_id); | 52 void UnregisterOperation(int request_id); |
53 | 53 |
54 private: | 54 private: |
55 void OnOpen(int request_id, | 55 void OnOpen(int request_id, |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
95 | 95 |
96 // This holds the ResourceContext until Init() can be called from the | 96 // This holds the ResourceContext until Init() can be called from the |
97 // IO thread, which will extract the net::URLRequestContext from it. | 97 // IO thread, which will extract the net::URLRequestContext from it. |
98 const content::ResourceContext* resource_context_; | 98 const content::ResourceContext* resource_context_; |
99 net::URLRequestContext* request_context_; | 99 net::URLRequestContext* request_context_; |
100 | 100 |
101 DISALLOW_COPY_AND_ASSIGN(FileSystemDispatcherHost); | 101 DISALLOW_COPY_AND_ASSIGN(FileSystemDispatcherHost); |
102 }; | 102 }; |
103 | 103 |
104 #endif // CONTENT_BROWSER_FILE_SYSTEM_FILE_SYSTEM_DISPATCHER_HOST_H_ | 104 #endif // CONTENT_BROWSER_FILE_SYSTEM_FILE_SYSTEM_DISPATCHER_HOST_H_ |
OLD | NEW |