| Index: chrome/browser/chromeos/fileapi/file_system_backend.h
|
| diff --git a/chrome/browser/chromeos/fileapi/file_system_backend.h b/chrome/browser/chromeos/fileapi/file_system_backend.h
|
| index ffccdf11d7bd0fe7db23a6ff297d6986c55e421e..a8109bfe277c5dd2ed0b663c0926f8e59f0d2b6b 100644
|
| --- a/chrome/browser/chromeos/fileapi/file_system_backend.h
|
| +++ b/chrome/browser/chromeos/fileapi/file_system_backend.h
|
| @@ -15,11 +15,11 @@
|
| #include "webkit/browser/quota/special_storage_policy.h"
|
| #include "webkit/common/fileapi/file_system_types.h"
|
|
|
| -namespace fileapi {
|
| +namespace storage {
|
| class CopyOrMoveFileValidatorFactory;
|
| class ExternalMountPoints;
|
| class FileSystemURL;
|
| -} // namespace fileapi
|
| +} // namespace storage
|
|
|
| namespace chromeos {
|
|
|
| @@ -58,9 +58,9 @@ class FileAccessPermissions;
|
| //
|
| // filesystem:<origin>/external/<mount_name>/...
|
| //
|
| -class FileSystemBackend : public fileapi::ExternalFileSystemBackend {
|
| +class FileSystemBackend : public storage::ExternalFileSystemBackend {
|
| public:
|
| - using fileapi::FileSystemBackend::OpenFileSystemCallback;
|
| + using storage::FileSystemBackend::OpenFileSystemCallback;
|
|
|
| // FileSystemBackend will take an ownership of a |mount_points|
|
| // reference. On the other hand, |system_mount_points| will be kept as a raw
|
| @@ -71,9 +71,9 @@ class FileSystemBackend : public fileapi::ExternalFileSystemBackend {
|
| FileSystemBackendDelegate* drive_delegate,
|
| FileSystemBackendDelegate* file_system_provider_delegate,
|
| FileSystemBackendDelegate* mtp_delegate,
|
| - scoped_refptr<quota::SpecialStoragePolicy> special_storage_policy,
|
| - scoped_refptr<fileapi::ExternalMountPoints> mount_points,
|
| - fileapi::ExternalMountPoints* system_mount_points);
|
| + scoped_refptr<storage::SpecialStoragePolicy> special_storage_policy,
|
| + scoped_refptr<storage::ExternalMountPoints> mount_points,
|
| + storage::ExternalMountPoints* system_mount_points);
|
| virtual ~FileSystemBackend();
|
|
|
| // Adds system mount points, such as "archive", and "removable". This
|
| @@ -83,42 +83,41 @@ class FileSystemBackend : public fileapi::ExternalFileSystemBackend {
|
| // Returns true if CrosMountpointProvider can handle |url|, i.e. its
|
| // file system type matches with what this provider supports.
|
| // This could be called on any threads.
|
| - static bool CanHandleURL(const fileapi::FileSystemURL& url);
|
| + static bool CanHandleURL(const storage::FileSystemURL& url);
|
|
|
| - // fileapi::FileSystemBackend overrides.
|
| - virtual bool CanHandleType(fileapi::FileSystemType type) const OVERRIDE;
|
| - virtual void Initialize(fileapi::FileSystemContext* context) OVERRIDE;
|
| - virtual void ResolveURL(const fileapi::FileSystemURL& url,
|
| - fileapi::OpenFileSystemMode mode,
|
| + // storage::FileSystemBackend overrides.
|
| + virtual bool CanHandleType(storage::FileSystemType type) const OVERRIDE;
|
| + virtual void Initialize(storage::FileSystemContext* context) OVERRIDE;
|
| + virtual void ResolveURL(const storage::FileSystemURL& url,
|
| + storage::OpenFileSystemMode mode,
|
| const OpenFileSystemCallback& callback) OVERRIDE;
|
| - virtual fileapi::AsyncFileUtil* GetAsyncFileUtil(
|
| - fileapi::FileSystemType type) OVERRIDE;
|
| - virtual fileapi::CopyOrMoveFileValidatorFactory*
|
| - GetCopyOrMoveFileValidatorFactory(
|
| - fileapi::FileSystemType type,
|
| - base::File::Error* error_code) OVERRIDE;
|
| - virtual fileapi::FileSystemOperation* CreateFileSystemOperation(
|
| - const fileapi::FileSystemURL& url,
|
| - fileapi::FileSystemContext* context,
|
| + virtual storage::AsyncFileUtil* GetAsyncFileUtil(
|
| + storage::FileSystemType type) OVERRIDE;
|
| + virtual storage::CopyOrMoveFileValidatorFactory*
|
| + GetCopyOrMoveFileValidatorFactory(storage::FileSystemType type,
|
| + base::File::Error* error_code) OVERRIDE;
|
| + virtual storage::FileSystemOperation* CreateFileSystemOperation(
|
| + const storage::FileSystemURL& url,
|
| + storage::FileSystemContext* context,
|
| base::File::Error* error_code) const OVERRIDE;
|
| virtual bool SupportsStreaming(
|
| - const fileapi::FileSystemURL& url) const OVERRIDE;
|
| + const storage::FileSystemURL& url) const OVERRIDE;
|
| virtual bool HasInplaceCopyImplementation(
|
| - fileapi::FileSystemType type) const OVERRIDE;
|
| - virtual scoped_ptr<webkit_blob::FileStreamReader> CreateFileStreamReader(
|
| - const fileapi::FileSystemURL& path,
|
| + storage::FileSystemType type) const OVERRIDE;
|
| + virtual scoped_ptr<storage::FileStreamReader> CreateFileStreamReader(
|
| + const storage::FileSystemURL& path,
|
| int64 offset,
|
| const base::Time& expected_modification_time,
|
| - fileapi::FileSystemContext* context) const OVERRIDE;
|
| - virtual scoped_ptr<fileapi::FileStreamWriter> CreateFileStreamWriter(
|
| - const fileapi::FileSystemURL& url,
|
| + storage::FileSystemContext* context) const OVERRIDE;
|
| + virtual scoped_ptr<storage::FileStreamWriter> CreateFileStreamWriter(
|
| + const storage::FileSystemURL& url,
|
| int64 offset,
|
| - fileapi::FileSystemContext* context) const OVERRIDE;
|
| - virtual fileapi::FileSystemQuotaUtil* GetQuotaUtil() OVERRIDE;
|
| + storage::FileSystemContext* context) const OVERRIDE;
|
| + virtual storage::FileSystemQuotaUtil* GetQuotaUtil() OVERRIDE;
|
|
|
| - // fileapi::ExternalFileSystemBackend overrides.
|
| - virtual bool IsAccessAllowed(const fileapi::FileSystemURL& url)
|
| - const OVERRIDE;
|
| + // storage::ExternalFileSystemBackend overrides.
|
| + virtual bool IsAccessAllowed(
|
| + const storage::FileSystemURL& url) const OVERRIDE;
|
| virtual std::vector<base::FilePath> GetRootDirectories() const OVERRIDE;
|
| virtual void GrantFullAccessToExtension(
|
| const std::string& extension_id) OVERRIDE;
|
| @@ -131,9 +130,9 @@ class FileSystemBackend : public fileapi::ExternalFileSystemBackend {
|
| base::FilePath* virtual_path) OVERRIDE;
|
|
|
| private:
|
| - scoped_refptr<quota::SpecialStoragePolicy> special_storage_policy_;
|
| + scoped_refptr<storage::SpecialStoragePolicy> special_storage_policy_;
|
| scoped_ptr<FileAccessPermissions> file_access_permissions_;
|
| - scoped_ptr<fileapi::AsyncFileUtil> local_file_util_;
|
| + scoped_ptr<storage::AsyncFileUtil> local_file_util_;
|
|
|
| // The delegate instance for the drive file system related operations.
|
| scoped_ptr<FileSystemBackendDelegate> drive_delegate_;
|
| @@ -155,11 +154,11 @@ class FileSystemBackend : public fileapi::ExternalFileSystemBackend {
|
| // |file_system_mount_points_| map 'xxx' to '/foo/foo1/xxx', |GetVirtualPaths|
|
| // will resolve '/foo/foo1/xxx/yyy' as 'foo1/xxx/yyy' (i.e. the mapping from
|
| // |mount_points_| will be used).
|
| - scoped_refptr<fileapi::ExternalMountPoints> mount_points_;
|
| + scoped_refptr<storage::ExternalMountPoints> mount_points_;
|
|
|
| // Globally visible mount points. System MountPonts instance should outlive
|
| // all FileSystemBackend instances, so raw pointer is safe.
|
| - fileapi::ExternalMountPoints* system_mount_points_;
|
| + storage::ExternalMountPoints* system_mount_points_;
|
|
|
| DISALLOW_COPY_AND_ASSIGN(FileSystemBackend);
|
| };
|
|
|