| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 WEBKIT_FILEAPI_ISOLATED_MOUNT_POINT_PROVIDER_H_ | 5 #ifndef WEBKIT_FILEAPI_ISOLATED_MOUNT_POINT_PROVIDER_H_ |
| 6 #define WEBKIT_FILEAPI_ISOLATED_MOUNT_POINT_PROVIDER_H_ | 6 #define WEBKIT_FILEAPI_ISOLATED_MOUNT_POINT_PROVIDER_H_ |
| 7 | 7 |
| 8 #include <vector> | |
| 9 | |
| 10 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 11 #include "webkit/fileapi/file_system_mount_point_provider.h" | 9 #include "webkit/fileapi/file_system_mount_point_provider.h" |
| 10 #include "webkit/fileapi/media/media_file_system_config.h" |
| 12 | 11 |
| 13 namespace fileapi { | 12 namespace fileapi { |
| 14 | 13 |
| 15 class DraggedFileUtil; | 14 class DraggedFileUtil; |
| 16 class IsolatedContext; | 15 class IsolatedContext; |
| 17 class IsolatedFileUtil; | 16 class IsolatedFileUtil; |
| 18 class MediaPathFilter; | 17 class MediaPathFilter; |
| 19 class NativeMediaFileUtil; | 18 class NativeMediaFileUtil; |
| 20 | 19 |
| 20 #if defined(SUPPORT_MEDIA_FILESYSTEM) |
| 21 class DeviceMediaFileUtil; |
| 22 #endif |
| 23 |
| 21 class IsolatedMountPointProvider : public FileSystemMountPointProvider { | 24 class IsolatedMountPointProvider : public FileSystemMountPointProvider { |
| 22 public: | 25 public: |
| 23 typedef FileSystemMountPointProvider::ValidateFileSystemCallback | 26 typedef FileSystemMountPointProvider::ValidateFileSystemCallback |
| 24 ValidateFileSystemCallback; | 27 ValidateFileSystemCallback; |
| 25 | 28 |
| 26 IsolatedMountPointProvider(); | 29 explicit IsolatedMountPointProvider(const FilePath& profile_path); |
| 27 virtual ~IsolatedMountPointProvider(); | 30 virtual ~IsolatedMountPointProvider(); |
| 28 | 31 |
| 29 // FileSystemMountPointProvider implementation. | 32 // FileSystemMountPointProvider implementation. |
| 30 virtual void ValidateFileSystemRoot( | 33 virtual void ValidateFileSystemRoot( |
| 31 const GURL& origin_url, | 34 const GURL& origin_url, |
| 32 FileSystemType type, | 35 FileSystemType type, |
| 33 bool create, | 36 bool create, |
| 34 const ValidateFileSystemCallback& callback) OVERRIDE; | 37 const ValidateFileSystemCallback& callback) OVERRIDE; |
| 35 virtual FilePath GetFileSystemRootPathOnFileThread( | 38 virtual FilePath GetFileSystemRootPathOnFileThread( |
| 36 const GURL& origin_url, | 39 const GURL& origin_url, |
| (...skipping 14 matching lines...) Expand all Loading... |
| 51 const FileSystemURL& url, | 54 const FileSystemURL& url, |
| 52 int64 offset, | 55 int64 offset, |
| 53 FileSystemContext* context) const OVERRIDE; | 56 FileSystemContext* context) const OVERRIDE; |
| 54 virtual FileStreamWriter* CreateFileStreamWriter( | 57 virtual FileStreamWriter* CreateFileStreamWriter( |
| 55 const FileSystemURL& url, | 58 const FileSystemURL& url, |
| 56 int64 offset, | 59 int64 offset, |
| 57 FileSystemContext* context) const OVERRIDE; | 60 FileSystemContext* context) const OVERRIDE; |
| 58 virtual FileSystemQuotaUtil* GetQuotaUtil() OVERRIDE; | 61 virtual FileSystemQuotaUtil* GetQuotaUtil() OVERRIDE; |
| 59 | 62 |
| 60 private: | 63 private: |
| 64 // Store the profile path. We need this to create temporary snapshot files. |
| 65 const FilePath profile_path_; |
| 66 |
| 61 scoped_ptr<MediaPathFilter> media_path_filter_; | 67 scoped_ptr<MediaPathFilter> media_path_filter_; |
| 62 | 68 |
| 63 scoped_ptr<IsolatedFileUtil> isolated_file_util_; | 69 scoped_ptr<IsolatedFileUtil> isolated_file_util_; |
| 64 scoped_ptr<DraggedFileUtil> dragged_file_util_; | 70 scoped_ptr<DraggedFileUtil> dragged_file_util_; |
| 65 scoped_ptr<NativeMediaFileUtil> native_media_file_util_; | 71 scoped_ptr<NativeMediaFileUtil> native_media_file_util_; |
| 72 |
| 73 #if defined(SUPPORT_MEDIA_FILESYSTEM) |
| 74 scoped_ptr<DeviceMediaFileUtil> device_media_file_util_; |
| 75 #endif |
| 66 }; | 76 }; |
| 67 | 77 |
| 68 } // namespace fileapi | 78 } // namespace fileapi |
| 69 | 79 |
| 70 #endif // WEBKIT_FILEAPI_ISOLATED_MOUNT_POINT_PROVIDER_H_ | 80 #endif // WEBKIT_FILEAPI_ISOLATED_MOUNT_POINT_PROVIDER_H_ |
| OLD | NEW |