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

Side by Side Diff: webkit/fileapi/file_system_operation_interface.h

Issue 10541113: Notify CloseFile from Pepper to FileSystem. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Added renderer-close check. Created 8 years, 6 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_FILEAPI_FILE_SYSTEM_OPERATION_INTERFACE_H_ 5 #ifndef WEBKIT_FILEAPI_FILE_SYSTEM_OPERATION_INTERFACE_H_
6 #define WEBKIT_FILEAPI_FILE_SYSTEM_OPERATION_INTERFACE_H_ 6 #define WEBKIT_FILEAPI_FILE_SYSTEM_OPERATION_INTERFACE_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/file_util_proxy.h" 10 #include "base/file_util_proxy.h"
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after
218 // 218 //
219 // |peer_handle| is the process handle of a pepper plugin process, which 219 // |peer_handle| is the process handle of a pepper plugin process, which
220 // is necessary for underlying IPC calls with Pepper plugins. 220 // is necessary for underlying IPC calls with Pepper plugins.
221 // 221 //
222 // This function is used only by Pepper as of writing. 222 // This function is used only by Pepper as of writing.
223 virtual void OpenFile(const GURL& path, 223 virtual void OpenFile(const GURL& path,
224 int file_flags, 224 int file_flags,
225 base::ProcessHandle peer_handle, 225 base::ProcessHandle peer_handle,
226 const OpenFileCallback& callback) = 0; 226 const OpenFileCallback& callback) = 0;
227 227
228 // Notifies a file at |path| opened by OpenFile is closed in plugin process.
229 // File system will run some cleanup task such as uploading the modified file
230 // content to a remote storage.
231 //
232 // This function is used only by Pepper as of writing.
233 virtual void NotifyCloseFile(const GURL& path) = 0;
234
228 // For downcasting to FileSystemOperation. 235 // For downcasting to FileSystemOperation.
229 // TODO(kinuko): this hack should go away once appropriate upload-stream 236 // TODO(kinuko): this hack should go away once appropriate upload-stream
230 // handling based on element types is supported. 237 // handling based on element types is supported.
231 virtual FileSystemOperation* AsFileSystemOperation() = 0; 238 virtual FileSystemOperation* AsFileSystemOperation() = 0;
232 239
233 // Creates a local snapshot file for a given |path| and returns the 240 // Creates a local snapshot file for a given |path| and returns the
234 // metadata and platform path of the snapshot file via |callback|. 241 // metadata and platform path of the snapshot file via |callback|.
235 // In local filesystem cases the implementation may simply return 242 // In local filesystem cases the implementation may simply return
236 // the metadata of the file itself (as well as GetMetadata does), 243 // the metadata of the file itself (as well as GetMetadata does),
237 // while in remote filesystem case the backend may want to download the file 244 // while in remote filesystem case the backend may want to download the file
(...skipping 14 matching lines...) Expand all
252 kOperationMove, 259 kOperationMove,
253 kOperationDirectoryExists, 260 kOperationDirectoryExists,
254 kOperationFileExists, 261 kOperationFileExists,
255 kOperationGetMetadata, 262 kOperationGetMetadata,
256 kOperationReadDirectory, 263 kOperationReadDirectory,
257 kOperationRemove, 264 kOperationRemove,
258 kOperationWrite, 265 kOperationWrite,
259 kOperationTruncate, 266 kOperationTruncate,
260 kOperationTouchFile, 267 kOperationTouchFile,
261 kOperationOpenFile, 268 kOperationOpenFile,
269 kOperationCloseFile,
262 kOperationGetLocalPath, 270 kOperationGetLocalPath,
263 kOperationCancel, 271 kOperationCancel,
264 }; 272 };
265 }; 273 };
266 274
267 } // namespace fileapi 275 } // namespace fileapi
268 276
269 #endif // WEBKIT_FILEAPI_FILE_SYSTEM_OPERATION_INTERFACE_H_ 277 #endif // WEBKIT_FILEAPI_FILE_SYSTEM_OPERATION_INTERFACE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698