Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(234)

Side by Side Diff: webkit/browser/fileapi/file_system_operation_impl.h

Issue 21370003: Rename fileapi::LocalFileSystemOperation to FileSystemOperationImpl. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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_LOCAL_FILE_SYSTEM_OPERATION_H_ 5 #ifndef WEBKIT_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_IMPL_H_
6 #define WEBKIT_BROWSER_FILEAPI_LOCAL_FILE_SYSTEM_OPERATION_H_ 6 #define WEBKIT_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_IMPL_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
11 #include "base/memory/scoped_ptr.h" 11 #include "base/memory/scoped_ptr.h"
12 #include "base/memory/weak_ptr.h" 12 #include "base/memory/weak_ptr.h"
13 #include "webkit/browser/fileapi/file_system_operation.h" 13 #include "webkit/browser/fileapi/file_system_operation.h"
14 #include "webkit/browser/fileapi/file_system_operation_context.h" 14 #include "webkit/browser/fileapi/file_system_operation_context.h"
15 #include "webkit/browser/fileapi/file_system_url.h" 15 #include "webkit/browser/fileapi/file_system_url.h"
16 #include "webkit/browser/fileapi/file_writer_delegate.h" 16 #include "webkit/browser/fileapi/file_writer_delegate.h"
17 #include "webkit/browser/webkit_storage_browser_export.h" 17 #include "webkit/browser/webkit_storage_browser_export.h"
18 #include "webkit/common/blob/scoped_file.h" 18 #include "webkit/common/blob/scoped_file.h"
19 #include "webkit/common/quota/quota_types.h" 19 #include "webkit/common/quota/quota_types.h"
20 20
21 namespace fileapi { 21 namespace fileapi {
22 22
23 class AsyncFileUtil; 23 class AsyncFileUtil;
24 class FileSystemContext; 24 class FileSystemContext;
25 class RecursiveOperationDelegate; 25 class RecursiveOperationDelegate;
26 26
27 // FileSystemOperation implementation for local file systems. 27 // The default implementation of FileSystemOperation for file systems.
28 class WEBKIT_STORAGE_BROWSER_EXPORT LocalFileSystemOperation 28 class WEBKIT_STORAGE_BROWSER_EXPORT FileSystemOperationImpl
29 : public NON_EXPORTED_BASE(FileSystemOperation), 29 : public NON_EXPORTED_BASE(FileSystemOperation),
30 public base::SupportsWeakPtr<LocalFileSystemOperation> { 30 public base::SupportsWeakPtr<FileSystemOperationImpl> {
31 public: 31 public:
32 // NOTE: This constructor should not be called outside FileSystemBackends; 32 // NOTE: This constructor should not be called outside FileSystemBackends;
33 // instead please consider using 33 // instead please consider using
34 // file_system_context->CreateFileSystemOperation() to instantiate 34 // file_system_context->CreateFileSystemOperation() to instantiate
35 // an appropriate FileSystemOperation. 35 // an appropriate FileSystemOperation.
36 LocalFileSystemOperation( 36 FileSystemOperationImpl(
37 const FileSystemURL& url, 37 const FileSystemURL& url,
38 FileSystemContext* file_system_context, 38 FileSystemContext* file_system_context,
39 scoped_ptr<FileSystemOperationContext> operation_context); 39 scoped_ptr<FileSystemOperationContext> operation_context);
40 40
41 virtual ~LocalFileSystemOperation(); 41 virtual ~FileSystemOperationImpl();
42 42
43 // FileSystemOperation overrides. 43 // FileSystemOperation overrides.
44 virtual void CreateFile(const FileSystemURL& url, 44 virtual void CreateFile(const FileSystemURL& url,
45 bool exclusive, 45 bool exclusive,
46 const StatusCallback& callback) OVERRIDE; 46 const StatusCallback& callback) OVERRIDE;
47 virtual void CreateDirectory(const FileSystemURL& url, 47 virtual void CreateDirectory(const FileSystemURL& url,
48 bool exclusive, 48 bool exclusive,
49 bool recursive, 49 bool recursive,
50 const StatusCallback& callback) OVERRIDE; 50 const StatusCallback& callback) OVERRIDE;
51 virtual void Copy(const FileSystemURL& src_url, 51 virtual void Copy(const FileSystemURL& src_url,
(...skipping 20 matching lines...) Expand all
72 const StatusCallback& callback) OVERRIDE; 72 const StatusCallback& callback) OVERRIDE;
73 virtual void TouchFile(const FileSystemURL& url, 73 virtual void TouchFile(const FileSystemURL& url,
74 const base::Time& last_access_time, 74 const base::Time& last_access_time,
75 const base::Time& last_modified_time, 75 const base::Time& last_modified_time,
76 const StatusCallback& callback) OVERRIDE; 76 const StatusCallback& callback) OVERRIDE;
77 virtual void OpenFile(const FileSystemURL& url, 77 virtual void OpenFile(const FileSystemURL& url,
78 int file_flags, 78 int file_flags,
79 base::ProcessHandle peer_handle, 79 base::ProcessHandle peer_handle,
80 const OpenFileCallback& callback) OVERRIDE; 80 const OpenFileCallback& callback) OVERRIDE;
81 virtual void Cancel(const StatusCallback& cancel_callback) OVERRIDE; 81 virtual void Cancel(const StatusCallback& cancel_callback) OVERRIDE;
82 virtual LocalFileSystemOperation* AsLocalFileSystemOperation() OVERRIDE; 82 virtual FileSystemOperationImpl* AsFileSystemOperationImpl() OVERRIDE;
83 virtual void CreateSnapshotFile( 83 virtual void CreateSnapshotFile(
84 const FileSystemURL& path, 84 const FileSystemURL& path,
85 const SnapshotFileCallback& callback) OVERRIDE; 85 const SnapshotFileCallback& callback) OVERRIDE;
86 86
87 // Copies in a single file from a different filesystem. 87 // Copies in a single file from a different filesystem.
88 // 88 //
89 // This returns: 89 // This returns:
90 // - PLATFORM_FILE_ERROR_NOT_FOUND if |src_file_path| 90 // - PLATFORM_FILE_ERROR_NOT_FOUND if |src_file_path|
91 // or the parent directory of |dest_url| does not exist. 91 // or the parent directory of |dest_url| does not exist.
92 // - PLATFORM_FILE_ERROR_INVALID_OPERATION if |dest_url| exists and 92 // - PLATFORM_FILE_ERROR_INVALID_OPERATION if |dest_url| exists and
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
248 248
249 StatusCallback cancel_callback_; 249 StatusCallback cancel_callback_;
250 250
251 // Used only by OpenFile, in order to clone the file handle back to the 251 // Used only by OpenFile, in order to clone the file handle back to the
252 // requesting process. 252 // requesting process.
253 base::ProcessHandle peer_handle_; 253 base::ProcessHandle peer_handle_;
254 254
255 // A flag to make sure we call operation only once per instance. 255 // A flag to make sure we call operation only once per instance.
256 OperationType pending_operation_; 256 OperationType pending_operation_;
257 257
258 DISALLOW_COPY_AND_ASSIGN(LocalFileSystemOperation); 258 DISALLOW_COPY_AND_ASSIGN(FileSystemOperationImpl);
259 }; 259 };
260 260
261 } // namespace fileapi 261 } // namespace fileapi
262 262
263 #endif // WEBKIT_BROWSER_FILEAPI_LOCAL_FILE_SYSTEM_OPERATION_H_ 263 #endif // WEBKIT_BROWSER_FILEAPI_FILE_SYSTEM_OPERATION_IMPL_H_
OLDNEW
« no previous file with comments | « webkit/browser/fileapi/file_system_operation.h ('k') | webkit/browser/fileapi/file_system_operation_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698