| 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_BROWSER_FILEAPI_TEST_FILE_SYSTEM_BACKEND_H_ | 5 #ifndef CONTENT_PUBLIC_TEST_TEST_FILE_SYSTEM_BACKEND_H_ |
| 6 #define WEBKIT_BROWSER_FILEAPI_TEST_FILE_SYSTEM_BACKEND_H_ | 6 #define CONTENT_PUBLIC_TEST_TEST_FILE_SYSTEM_BACKEND_H_ |
| 7 | 7 |
| 8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| 11 #include "webkit/browser/fileapi/async_file_util_adapter.h" | 11 #include "webkit/browser/fileapi/async_file_util_adapter.h" |
| 12 #include "webkit/browser/fileapi/file_system_backend.h" | 12 #include "webkit/browser/fileapi/file_system_backend.h" |
| 13 #include "webkit/browser/fileapi/task_runner_bound_observer_list.h" | 13 #include "webkit/browser/fileapi/task_runner_bound_observer_list.h" |
| 14 #include "webkit/browser/webkit_storage_browser_export.h" | |
| 15 | 14 |
| 16 namespace base { | 15 namespace base { |
| 17 class SequencedTaskRunner; | 16 class SequencedTaskRunner; |
| 18 } | 17 } |
| 19 | 18 |
| 20 namespace fileapi { | 19 namespace fileapi { |
| 21 | 20 |
| 22 class AsyncFileUtilAdapter; | 21 class AsyncFileUtilAdapter; |
| 23 class FileSystemQuotaUtil; | 22 class FileSystemQuotaUtil; |
| 24 | 23 |
| 25 // This should be only used for testing. | 24 // This should be only used for testing. |
| 26 // This file system backend uses LocalFileUtil and stores data file | 25 // This file system backend uses LocalFileUtil and stores data file |
| 27 // under the given directory. | 26 // under the given directory. |
| 28 class WEBKIT_STORAGE_BROWSER_EXPORT_PRIVATE TestFileSystemBackend | 27 class TestFileSystemBackend : public FileSystemBackend { |
| 29 : public FileSystemBackend { | |
| 30 public: | 28 public: |
| 31 TestFileSystemBackend( | 29 TestFileSystemBackend( |
| 32 base::SequencedTaskRunner* task_runner, | 30 base::SequencedTaskRunner* task_runner, |
| 33 const base::FilePath& base_path); | 31 const base::FilePath& base_path); |
| 34 virtual ~TestFileSystemBackend(); | 32 virtual ~TestFileSystemBackend(); |
| 35 | 33 |
| 36 // FileSystemBackend implementation. | 34 // FileSystemBackend implementation. |
| 37 virtual bool CanHandleType(FileSystemType type) const OVERRIDE; | 35 virtual bool CanHandleType(FileSystemType type) const OVERRIDE; |
| 38 virtual void Initialize(FileSystemContext* context) OVERRIDE; | 36 virtual void Initialize(FileSystemContext* context) OVERRIDE; |
| 39 virtual void OpenFileSystem( | 37 virtual void OpenFileSystem( |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 | 83 |
| 86 bool require_copy_or_move_validator_; | 84 bool require_copy_or_move_validator_; |
| 87 scoped_ptr<CopyOrMoveFileValidatorFactory> | 85 scoped_ptr<CopyOrMoveFileValidatorFactory> |
| 88 copy_or_move_file_validator_factory_; | 86 copy_or_move_file_validator_factory_; |
| 89 | 87 |
| 90 DISALLOW_COPY_AND_ASSIGN(TestFileSystemBackend); | 88 DISALLOW_COPY_AND_ASSIGN(TestFileSystemBackend); |
| 91 }; | 89 }; |
| 92 | 90 |
| 93 } // namespace fileapi | 91 } // namespace fileapi |
| 94 | 92 |
| 95 #endif // WEBKIT_BROWSER_FILEAPI_TEST_FILE_SYSTEM_BACKEND_H_ | 93 #endif // CONTENT_PUBLIC_TEST_TEST_FILE_SYSTEM_BACKEND_H_ |
| OLD | NEW |