| 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_SYNC_FILE_SYSTEM_LOCAL_SYNC_FILE_SYSTEM_BACKEND_H_ | 5 #ifndef CHROME_BROWSER_SYNC_FILE_SYSTEM_LOCAL_SYNC_FILE_SYSTEM_BACKEND_H_ |
| 6 #define CHROME_BROWSER_SYNC_FILE_SYSTEM_LOCAL_SYNC_FILE_SYSTEM_BACKEND_H_ | 6 #define CHROME_BROWSER_SYNC_FILE_SYSTEM_LOCAL_SYNC_FILE_SYSTEM_BACKEND_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <memory> |
| 11 |
| 10 #include "base/macros.h" | 12 #include "base/macros.h" |
| 11 #include "chrome/browser/profiles/profile.h" | 13 #include "chrome/browser/profiles/profile.h" |
| 12 #include "chrome/browser/sync_file_system/sync_callbacks.h" | 14 #include "chrome/browser/sync_file_system/sync_callbacks.h" |
| 13 #include "chrome/browser/sync_file_system/sync_status_code.h" | 15 #include "chrome/browser/sync_file_system/sync_status_code.h" |
| 14 #include "content/public/browser/notification_observer.h" | 16 #include "content/public/browser/notification_observer.h" |
| 15 #include "content/public/browser/notification_registrar.h" | 17 #include "content/public/browser/notification_registrar.h" |
| 16 #include "storage/browser/fileapi/file_system_backend.h" | 18 #include "storage/browser/fileapi/file_system_backend.h" |
| 17 #include "storage/browser/fileapi/file_system_quota_util.h" | 19 #include "storage/browser/fileapi/file_system_quota_util.h" |
| 18 #include "storage/browser/fileapi/sandbox_file_system_backend_delegate.h" | 20 #include "storage/browser/fileapi/sandbox_file_system_backend_delegate.h" |
| 19 #include "storage/browser/fileapi/task_runner_bound_observer_list.h" | 21 #include "storage/browser/fileapi/task_runner_bound_observer_list.h" |
| 20 | 22 |
| 21 namespace sync_file_system { | 23 namespace sync_file_system { |
| 22 | 24 |
| 23 class LocalFileChangeTracker; | 25 class LocalFileChangeTracker; |
| 24 class LocalFileSyncContext; | 26 class LocalFileSyncContext; |
| 25 | 27 |
| 26 class SyncFileSystemBackend : public storage::FileSystemBackend { | 28 class SyncFileSystemBackend : public storage::FileSystemBackend { |
| 27 public: | 29 public: |
| 28 explicit SyncFileSystemBackend(Profile* profile); | 30 explicit SyncFileSystemBackend(Profile* profile); |
| 29 ~SyncFileSystemBackend() override; | 31 ~SyncFileSystemBackend() override; |
| 30 | 32 |
| 31 static SyncFileSystemBackend* CreateForTesting(); | 33 static std::unique_ptr<SyncFileSystemBackend> CreateForTesting(); |
| 32 | 34 |
| 33 // FileSystemBackend overrides. | 35 // FileSystemBackend overrides. |
| 34 bool CanHandleType(storage::FileSystemType type) const override; | 36 bool CanHandleType(storage::FileSystemType type) const override; |
| 35 void Initialize(storage::FileSystemContext* context) override; | 37 void Initialize(storage::FileSystemContext* context) override; |
| 36 void ResolveURL(const storage::FileSystemURL& url, | 38 void ResolveURL(const storage::FileSystemURL& url, |
| 37 storage::OpenFileSystemMode mode, | 39 storage::OpenFileSystemMode mode, |
| 38 const OpenFileSystemCallback& callback) override; | 40 const OpenFileSystemCallback& callback) override; |
| 39 storage::AsyncFileUtil* GetAsyncFileUtil( | 41 storage::AsyncFileUtil* GetAsyncFileUtil( |
| 40 storage::FileSystemType type) override; | 42 storage::FileSystemType type) override; |
| 41 storage::WatcherManager* GetWatcherManager( | 43 storage::WatcherManager* GetWatcherManager( |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 storage::OpenFileSystemMode mode, | 122 storage::OpenFileSystemMode mode, |
| 121 const OpenFileSystemCallback& callback, | 123 const OpenFileSystemCallback& callback, |
| 122 SyncStatusCode status); | 124 SyncStatusCode status); |
| 123 | 125 |
| 124 DISALLOW_COPY_AND_ASSIGN(SyncFileSystemBackend); | 126 DISALLOW_COPY_AND_ASSIGN(SyncFileSystemBackend); |
| 125 }; | 127 }; |
| 126 | 128 |
| 127 } // namespace sync_file_system | 129 } // namespace sync_file_system |
| 128 | 130 |
| 129 #endif // CHROME_BROWSER_SYNC_FILE_SYSTEM_LOCAL_SYNC_FILE_SYSTEM_BACKEND_H_ | 131 #endif // CHROME_BROWSER_SYNC_FILE_SYSTEM_LOCAL_SYNC_FILE_SYSTEM_BACKEND_H_ |
| OLD | NEW |