| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CHROME_BROWSER_CHROMEOS_DRIVE_MOUNT_POINT_PROVIDER_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_DRIVE_FILE_SYSTEM_BACKEND_DELEGATE_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_DRIVE_MOUNT_POINT_PROVIDER_DELEGATE_H_ | 6 #define CHROME_BROWSER_CHROMEOS_DRIVE_FILE_SYSTEM_BACKEND_DELEGATE_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "chrome/browser/chromeos/fileapi/cros_mount_point_provider_delegate.h" | 10 #include "chrome/browser/chromeos/fileapi/file_system_backend_delegate.h" |
| 11 | 11 |
| 12 namespace fileapi { | 12 namespace fileapi { |
| 13 class ExternalMountPoints; | 13 class ExternalMountPoints; |
| 14 } // namespace fileapi | 14 } // namespace fileapi |
| 15 | 15 |
| 16 namespace drive { | 16 namespace drive { |
| 17 | 17 |
| 18 // Delegate implementation of the some methods in CrosMountPointProvider | 18 // Delegate implementation of the some methods in chromeos::FileSystemBackend |
| 19 // for Drive file system. | 19 // for Drive file system. |
| 20 class MountPointProviderDelegate | 20 class FileSystemBackendDelegate : public chromeos::FileSystemBackendDelegate { |
| 21 : public chromeos::CrosMountPointProviderDelegate { | |
| 22 public: | 21 public: |
| 23 explicit MountPointProviderDelegate( | 22 explicit FileSystemBackendDelegate( |
| 24 fileapi::ExternalMountPoints* mount_points); | 23 fileapi::ExternalMountPoints* mount_points); |
| 25 virtual ~MountPointProviderDelegate(); | 24 virtual ~FileSystemBackendDelegate(); |
| 26 | 25 |
| 27 // CrosMountPointProvider::Delegate overrides. | 26 // FileSystemBackend::Delegate overrides. |
| 28 virtual fileapi::AsyncFileUtil* GetAsyncFileUtil( | 27 virtual fileapi::AsyncFileUtil* GetAsyncFileUtil( |
| 29 fileapi::FileSystemType type) OVERRIDE; | 28 fileapi::FileSystemType type) OVERRIDE; |
| 30 virtual scoped_ptr<webkit_blob::FileStreamReader> CreateFileStreamReader( | 29 virtual scoped_ptr<webkit_blob::FileStreamReader> CreateFileStreamReader( |
| 31 const fileapi::FileSystemURL& url, | 30 const fileapi::FileSystemURL& url, |
| 32 int64 offset, | 31 int64 offset, |
| 33 const base::Time& expected_modification_time, | 32 const base::Time& expected_modification_time, |
| 34 fileapi::FileSystemContext* context) OVERRIDE; | 33 fileapi::FileSystemContext* context) OVERRIDE; |
| 35 virtual scoped_ptr<fileapi::FileStreamWriter> CreateFileStreamWriter( | 34 virtual scoped_ptr<fileapi::FileStreamWriter> CreateFileStreamWriter( |
| 36 const fileapi::FileSystemURL& url, | 35 const fileapi::FileSystemURL& url, |
| 37 int64 offset, | 36 int64 offset, |
| 38 fileapi::FileSystemContext* context) OVERRIDE; | 37 fileapi::FileSystemContext* context) OVERRIDE; |
| 39 virtual fileapi::FileSystemOperation* CreateFileSystemOperation( | 38 virtual fileapi::FileSystemOperation* CreateFileSystemOperation( |
| 40 const fileapi::FileSystemURL& url, | 39 const fileapi::FileSystemURL& url, |
| 41 fileapi::FileSystemContext* context, | 40 fileapi::FileSystemContext* context, |
| 42 base::PlatformFileError* error_code) OVERRIDE; | 41 base::PlatformFileError* error_code) OVERRIDE; |
| 43 | 42 |
| 44 private: | 43 private: |
| 45 scoped_refptr<fileapi::ExternalMountPoints> mount_points_; | 44 scoped_refptr<fileapi::ExternalMountPoints> mount_points_; |
| 46 | 45 |
| 47 DISALLOW_COPY_AND_ASSIGN(MountPointProviderDelegate); | 46 DISALLOW_COPY_AND_ASSIGN(FileSystemBackendDelegate); |
| 48 }; | 47 }; |
| 49 | 48 |
| 50 } // namespace drive | 49 } // namespace drive |
| 51 | 50 |
| 52 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_MOUNT_POINT_PROVIDER_DELEGATE_H_ | 51 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_FILE_SYSTEM_BACKEND_DELEGATE_H_ |
| OLD | NEW |