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_FILE_SYSTEM_OPERATION_H_ | 5 #ifndef WEBKIT_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_H_ |
6 #define WEBKIT_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_H_ | 6 #define WEBKIT_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/callback.h" | 10 #include "base/callback.h" |
(...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
320 // - PLATFORM_FILE_ERROR_INVALID_OPERATION if |dest_url| exists and | 320 // - PLATFORM_FILE_ERROR_INVALID_OPERATION if |dest_url| exists and |
321 // is not a file. | 321 // is not a file. |
322 // - PLATFORM_FILE_ERROR_FAILED if |dest_url| does not exist and | 322 // - PLATFORM_FILE_ERROR_FAILED if |dest_url| does not exist and |
323 // its parent path is a file. | 323 // its parent path is a file. |
324 // | 324 // |
325 virtual void MoveFileLocal(const FileSystemURL& src_url, | 325 virtual void MoveFileLocal(const FileSystemURL& src_url, |
326 const FileSystemURL& dest_url, | 326 const FileSystemURL& dest_url, |
327 const StatusCallback& callback) = 0; | 327 const StatusCallback& callback) = 0; |
328 | 328 |
329 // Synchronously gets the platform path for the given |url|. | 329 // Synchronously gets the platform path for the given |url|. |
330 // This may fail if |file_system_context| returns NULL on GetFileUtil(). | 330 // This may fail if the given |url|'s filesystem type is neither |
| 331 // temporary nor persistent. |
331 // In such a case, base::PLATFORM_FILE_ERROR_INVALID_OPERATION will be | 332 // In such a case, base::PLATFORM_FILE_ERROR_INVALID_OPERATION will be |
332 // returned. | 333 // returned. |
333 virtual base::PlatformFileError SyncGetPlatformPath( | 334 virtual base::PlatformFileError SyncGetPlatformPath( |
334 const FileSystemURL& url, | 335 const FileSystemURL& url, |
335 base::FilePath* platform_path) = 0; | 336 base::FilePath* platform_path) = 0; |
336 | 337 |
337 protected: | 338 protected: |
338 // Used only for internal assertions. | 339 // Used only for internal assertions. |
339 enum OperationType { | 340 enum OperationType { |
340 kOperationNone, | 341 kOperationNone, |
(...skipping 14 matching lines...) Expand all Loading... |
355 kOperationOpenFile, | 356 kOperationOpenFile, |
356 kOperationCloseFile, | 357 kOperationCloseFile, |
357 kOperationGetLocalPath, | 358 kOperationGetLocalPath, |
358 kOperationCancel, | 359 kOperationCancel, |
359 }; | 360 }; |
360 }; | 361 }; |
361 | 362 |
362 } // namespace fileapi | 363 } // namespace fileapi |
363 | 364 |
364 #endif // WEBKIT_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_H_ | 365 #endif // WEBKIT_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_H_ |
OLD | NEW |