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 CONTENT_PUBLIC_TEST_SANDBOX_FILE_SYSTEM_TEST_HELPER_H_ | 5 #ifndef CONTENT_PUBLIC_TEST_SANDBOX_FILE_SYSTEM_TEST_HELPER_H_ |
6 #define CONTENT_PUBLIC_TEST_SANDBOX_FILE_SYSTEM_TEST_HELPER_H_ | 6 #define CONTENT_PUBLIC_TEST_SANDBOX_FILE_SYSTEM_TEST_HELPER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/files/file_path.h" | 10 #include "base/files/file_path.h" |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 | 70 |
71 // This doesn't work with OFSFU. | 71 // This doesn't work with OFSFU. |
72 int64 ComputeCurrentOriginUsage(); | 72 int64 ComputeCurrentOriginUsage(); |
73 | 73 |
74 int64 ComputeCurrentDirectoryDatabaseUsage(); | 74 int64 ComputeCurrentDirectoryDatabaseUsage(); |
75 | 75 |
76 storage::FileSystemOperationRunner* operation_runner(); | 76 storage::FileSystemOperationRunner* operation_runner(); |
77 storage::FileSystemOperationContext* NewOperationContext(); | 77 storage::FileSystemOperationContext* NewOperationContext(); |
78 | 78 |
79 void AddFileChangeObserver(storage::FileChangeObserver* observer); | 79 void AddFileChangeObserver(storage::FileChangeObserver* observer); |
| 80 void AddFileUpdateObserver(storage::FileUpdateObserver* observer); |
80 | 81 |
81 storage::FileSystemContext* file_system_context() const { | 82 storage::FileSystemContext* file_system_context() const { |
82 return file_system_context_.get(); | 83 return file_system_context_.get(); |
83 } | 84 } |
84 | 85 |
85 const GURL& origin() const { return origin_; } | 86 const GURL& origin() const { return origin_; } |
86 storage::FileSystemType type() const { return type_; } | 87 storage::FileSystemType type() const { return type_; } |
87 storage::StorageType storage_type() const { | 88 storage::StorageType storage_type() const { |
88 return storage::FileSystemTypeToQuotaStorageType(type_); | 89 return storage::FileSystemTypeToQuotaStorageType(type_); |
89 } | 90 } |
90 storage::FileSystemFileUtil* file_util() const { return file_util_; } | 91 storage::FileSystemFileUtil* file_util() const { return file_util_; } |
91 storage::FileSystemUsageCache* usage_cache(); | 92 storage::FileSystemUsageCache* usage_cache(); |
92 | 93 |
93 private: | 94 private: |
94 void SetUpFileSystem(); | 95 void SetUpFileSystem(); |
95 | 96 |
96 scoped_refptr<storage::FileSystemContext> file_system_context_; | 97 scoped_refptr<storage::FileSystemContext> file_system_context_; |
97 | 98 |
98 const GURL origin_; | 99 const GURL origin_; |
99 const storage::FileSystemType type_; | 100 const storage::FileSystemType type_; |
100 storage::FileSystemFileUtil* file_util_; | 101 storage::FileSystemFileUtil* file_util_; |
101 }; | 102 }; |
102 | 103 |
103 } // namespace content | 104 } // namespace content |
104 | 105 |
105 #endif // CONTENT_PUBLIC_TEST_SANDBOX_FILE_SYSTEM_TEST_HELPER_H_ | 106 #endif // CONTENT_PUBLIC_TEST_SANDBOX_FILE_SYSTEM_TEST_HELPER_H_ |
OLD | NEW |