OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CHROME_BROWSER_FILE_SYSTEM_FILE_SYSTEM_DISPATCHER_HOST_H_ |
| 6 #define CHROME_BROWSER_FILE_SYSTEM_FILE_SYSTEM_DISPATCHER_HOST_H_ |
| 7 |
| 8 #include "base/basictypes.h" |
| 9 #include "base/nullable_string16.h" |
| 10 #include "base/process.h" |
| 11 #include "base/ref_counted.h" |
| 12 #include "chrome/common/render_messages.h" |
| 13 |
| 14 class HostContentSettingsMap; |
| 15 class Receiver; |
| 16 class ResourceMessageFilter; |
| 17 |
| 18 class FileSystemDispatcherHost |
| 19 : public base::RefCountedThreadSafe<FileSystemDispatcherHost> { |
| 20 public: |
| 21 FileSystemDispatcherHost(IPC::Message::Sender* sender, |
| 22 HostContentSettingsMap* host_content_settings_map); |
| 23 void Init(base::ProcessHandle process_handle); |
| 24 void Shutdown(); |
| 25 |
| 26 bool OnMessageReceived(const IPC::Message& message, bool* message_was_ok); |
| 27 |
| 28 void OnOpenFileSystem(const ViewHostMsg_OpenFileSystemRequest_Params&); |
| 29 // TODO(kinuko): add more methods. |
| 30 |
| 31 void Send(IPC::Message* message); |
| 32 |
| 33 private: |
| 34 // The sender to be used for sending out IPC messages. |
| 35 IPC::Message::Sender* message_sender_; |
| 36 |
| 37 // The handle of this process. |
| 38 base::ProcessHandle process_handle_; |
| 39 |
| 40 bool shutdown_; |
| 41 |
| 42 // Used to look up permissions. |
| 43 scoped_refptr<HostContentSettingsMap> host_content_settings_map_; |
| 44 }; |
| 45 |
| 46 #endif // CHROME_BROWSER_FILE_SYSTEM_FILE_SYSTEM_DISPATCHER_HOST_H_ |
OLD | NEW |