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 #include "webkit/fileapi/test_mount_point_provider.h" | 5 #include "webkit/fileapi/test_mount_point_provider.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
127 base::PlatformFileError* error_code) const { | 127 base::PlatformFileError* error_code) const { |
128 scoped_ptr<FileSystemOperationContext> operation_context( | 128 scoped_ptr<FileSystemOperationContext> operation_context( |
129 new FileSystemOperationContext(context)); | 129 new FileSystemOperationContext(context)); |
130 operation_context->set_update_observers(observers_); | 130 operation_context->set_update_observers(observers_); |
131 return new LocalFileSystemOperation(context, operation_context.Pass()); | 131 return new LocalFileSystemOperation(context, operation_context.Pass()); |
132 } | 132 } |
133 | 133 |
134 webkit_blob::FileStreamReader* TestMountPointProvider::CreateFileStreamReader( | 134 webkit_blob::FileStreamReader* TestMountPointProvider::CreateFileStreamReader( |
135 const FileSystemURL& url, | 135 const FileSystemURL& url, |
136 int64 offset, | 136 int64 offset, |
| 137 const base::Time& expected_modification_time, |
137 FileSystemContext* context) const { | 138 FileSystemContext* context) const { |
138 return new FileSystemFileStreamReader(context, url, offset); | 139 return new FileSystemFileStreamReader( |
| 140 context, url, offset, expected_modification_time); |
139 } | 141 } |
140 | 142 |
141 fileapi::FileStreamWriter* TestMountPointProvider::CreateFileStreamWriter( | 143 fileapi::FileStreamWriter* TestMountPointProvider::CreateFileStreamWriter( |
142 const FileSystemURL& url, | 144 const FileSystemURL& url, |
143 int64 offset, | 145 int64 offset, |
144 FileSystemContext* context) const { | 146 FileSystemContext* context) const { |
145 return new SandboxFileStreamWriter(context, url, offset, observers_); | 147 return new SandboxFileStreamWriter(context, url, offset, observers_); |
146 } | 148 } |
147 | 149 |
148 FileSystemQuotaUtil* TestMountPointProvider::GetQuotaUtil() { | 150 FileSystemQuotaUtil* TestMountPointProvider::GetQuotaUtil() { |
(...skipping 10 matching lines...) Expand all Loading... |
159 NOTREACHED(); | 161 NOTREACHED(); |
160 callback.Run(base::PLATFORM_FILE_ERROR_INVALID_OPERATION); | 162 callback.Run(base::PLATFORM_FILE_ERROR_INVALID_OPERATION); |
161 } | 163 } |
162 | 164 |
163 const UpdateObserverList* TestMountPointProvider::GetUpdateObservers( | 165 const UpdateObserverList* TestMountPointProvider::GetUpdateObservers( |
164 FileSystemType type) const { | 166 FileSystemType type) const { |
165 return &observers_; | 167 return &observers_; |
166 } | 168 } |
167 | 169 |
168 } // namespace fileapi | 170 } // namespace fileapi |
OLD | NEW |