Index: webkit/fileapi/file_system_context.h |
diff --git a/webkit/fileapi/file_system_context.h b/webkit/fileapi/file_system_context.h |
index a797cebcfb00495d2763f476b40488e02ab50c10..4d5ab5580190a9bd02b0925e7eff67a81abb2dfb 100644 |
--- a/webkit/fileapi/file_system_context.h |
+++ b/webkit/fileapi/file_system_context.h |
@@ -23,7 +23,11 @@ class QuotaManagerProxy; |
namespace fileapi { |
+class ExternalFileSystemMountPointProvider; |
class FileSystemContext; |
+class FileSystemFileUtil; |
+class FileSystemMountPointProvider; |
+class FileSystemOptions; |
class FileSystemPathManager; |
class FileSystemQuotaUtil; |
class SandboxMountPointProvider; |
@@ -42,9 +46,7 @@ class FileSystemContext |
scoped_refptr<quota::SpecialStoragePolicy> special_storage_policy, |
quota::QuotaManagerProxy* quota_manager_proxy, |
const FilePath& profile_path, |
- bool is_incognito, |
- bool allow_file_access_from_files, |
- FileSystemPathManager* path_manager); |
+ const FileSystemOptions& options); |
~FileSystemContext(); |
// This method can be called on any thread. |
@@ -52,7 +54,6 @@ class FileSystemContext |
bool DeleteDataForOriginAndTypeOnFileThread(const GURL& origin_url, |
FileSystemType type); |
- FileSystemPathManager* path_manager() const { return path_manager_.get(); } |
quota::QuotaManagerProxy* quota_manager_proxy() const { |
return quota_manager_proxy_.get(); |
} |
@@ -62,17 +63,39 @@ class FileSystemContext |
// it is not a quota-managed storage. |
FileSystemQuotaUtil* GetQuotaUtil(FileSystemType type) const; |
+ // Returns the appropriate FileUtil instance for the given |type|. |
+ // This may return NULL if it is given an invalid or unsupported filesystem |
+ // type. |
+ FileSystemFileUtil* GetFileUtil(FileSystemType type) const; |
+ |
+ // Returns the mount point provider instance for the given |type|. |
+ // This may return NULL if it is given an invalid or unsupported filesystem |
+ // type. |
+ FileSystemMountPointProvider* GetMountPointProvider( |
+ FileSystemType type) const; |
+ |
+ // Returns a FileSystemMountPointProvider instance for sandboxed filesystem |
+ // types (e.g. TEMPORARY or PERSISTENT). This is equivalent to calling |
+ // GetMountPointProvider(kFileSystemType{Temporary, Persistent}). |
+ SandboxMountPointProvider* sandbox_provider() const; |
+ |
+ // Returns a FileSystemMountPointProvider instance for external filesystem |
+ // type, which is used only by chromeos for now. This is equivalent to |
+ // calling GetMountPointProvider(kFileSystemTypeExternal). |
+ ExternalFileSystemMountPointProvider* external_provider() const; |
+ |
private: |
friend struct DefaultContextDeleter; |
void DeleteOnCorrectThread() const; |
- SandboxMountPointProvider* sandbox_provider() const; |
scoped_refptr<base::MessageLoopProxy> file_message_loop_; |
scoped_refptr<base::MessageLoopProxy> io_message_loop_; |
scoped_refptr<quota::QuotaManagerProxy> quota_manager_proxy_; |
- scoped_ptr<FileSystemPathManager> path_manager_; |
+ // Mount point providers. |
+ scoped_ptr<SandboxMountPointProvider> sandbox_provider_; |
+ scoped_ptr<ExternalFileSystemMountPointProvider> external_provider_; |
DISALLOW_IMPLICIT_CONSTRUCTORS(FileSystemContext); |
}; |