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

Unified Diff: chrome/common/file_system/file_system_dispatcher.h

Issue 3208007: Add final part of IPC plumbing for FileSystem API (Closed)
Patch Set: fixing Created 10 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 side-by-side diff with in-line comments
Download patch
Index: chrome/common/file_system/file_system_dispatcher.h
diff --git a/chrome/common/file_system/file_system_dispatcher.h b/chrome/common/file_system/file_system_dispatcher.h
index 5c854c20ba1e1931f9535cd1bbcb479c7417c032..70855d1221ccb6bb278c25d6561b303a5d3fa208 100644
--- a/chrome/common/file_system/file_system_dispatcher.h
+++ b/chrome/common/file_system/file_system_dispatcher.h
@@ -13,11 +13,20 @@
#include "googleurl/src/gurl.h"
#include "ipc/ipc_channel.h"
#include "ipc/ipc_message.h"
+#include "third_party/WebKit/WebKit/chromium/public/WebFileError.h"
namespace WebKit {
+struct WebFileInfo;
class WebFileSystemCallbacks;
+struct WebFileSystemEntry;
}
+namespace file_util {
+struct FileInfo;
+}
+
+struct ViewMsg_FileSystem_DidReadDirectory_Params;
+
// Dispatches and sends file system related messages sent to/from a child
// process from/to the main browser process. There is one instance
// per child process. Messages are dispatched on the main child thread.
@@ -32,13 +41,39 @@ class FileSystemDispatcher {
const string16& src_path,
const string16& dest_path,
WebKit::WebFileSystemCallbacks* callbacks);
-
- // TODO(kinuko): add more implementation.
+ void Copy(
+ const string16& src_path,
+ const string16& dest_path,
+ WebKit::WebFileSystemCallbacks* callbacks);
+ void Remove(
+ const string16& path,
+ WebKit::WebFileSystemCallbacks* callbacks);
+ void ReadMetadata(
+ const string16& path,
+ WebKit::WebFileSystemCallbacks* callbacks);
+ void Create(
+ const string16& path,
+ bool exclusive,
+ bool for_directory,
+ WebKit::WebFileSystemCallbacks* callbacks);
+ void Exists(
+ const string16& path,
+ bool for_directory,
+ WebKit::WebFileSystemCallbacks* callbacks);
+ void ReadDirectory(
+ const string16& path,
+ WebKit::WebFileSystemCallbacks* callbacks);
private:
- void DidSucceed(int32 callbacks_id);
- void DidFail(int32 callbacks_id, int code);
- // TODO(kinuko): add more callbacks.
+ void DidSucceed(int request_id);
+ void DidReadMetadata(
+ int request_id,
+ const file_util::FileInfo& file_info);
+ void DidReadDirectory(
+ const ViewMsg_FileSystem_DidReadDirectory_Params& params);
+ void DidFail(
+ int request_id,
+ WebKit::WebFileError);
IDMap<WebKit::WebFileSystemCallbacks> callbacks_;

Powered by Google App Engine
This is Rietveld 408576698