Index: webkit/browser/fileapi/file_system_context.h |
diff --git a/webkit/browser/fileapi/file_system_context.h b/webkit/browser/fileapi/file_system_context.h |
index 9762b68ebc1c15708c5318f4fa5b285c10a91227..21a31b89eb8be4e603ce3a068f8cd02cd4496bee 100644 |
--- a/webkit/browser/fileapi/file_system_context.h |
+++ b/webkit/browser/fileapi/file_system_context.h |
@@ -49,8 +49,8 @@ class CopyOrMoveFileValidatorFactory; |
class ExternalFileSystemBackend; |
class ExternalMountPoints; |
class FileStreamWriter; |
-class FileSystemFileUtil; |
class FileSystemBackend; |
+class FileSystemFileUtil; |
class FileSystemOperation; |
class FileSystemOperationRunner; |
class FileSystemOptions; |
@@ -61,6 +61,7 @@ class MountPoints; |
class SandboxFileSystemBackend; |
struct DefaultContextDeleter; |
+struct FileSystemInfo; |
// This class keeps and provides a file system context for FileSystem API. |
// An instance of this class is created and owned by profile. |
@@ -154,6 +155,12 @@ class WEBKIT_STORAGE_BROWSER_EXPORT FileSystemContext |
const std::string& name, |
const GURL& root)> OpenFileSystemCallback; |
+ // Used for ResolveURL. |
+ typedef base::Callback<void(base::PlatformFileError result, |
+ const FileSystemInfo& info, |
+ const base::FilePath& file_path, |
+ bool is_directory)> ResolveURLCallback; |
+ |
// Used for DeleteFileSystem. |
typedef base::Callback<void(base::PlatformFileError result)> |
DeleteFileSystemCallback; |
@@ -169,8 +176,15 @@ class WEBKIT_STORAGE_BROWSER_EXPORT FileSystemContext |
OpenFileSystemMode mode, |
const OpenFileSystemCallback& callback); |
+ // Opens the filesystem for the given |url| as read-only, and then checks the |
+ // existence of the file entry referred by the URL. This should be called on |
+ // the IO thread. |
+ void ResolveURL( |
+ const FileSystemURL& url, |
+ const ResolveURLCallback& callback); |
+ |
// Deletes the filesystem for the given |origin_url| and |type|. This should |
- // be called on the IO Thread. |
+ // be called on the IO thread. |
void DeleteFileSystem( |
const GURL& origin_url, |
FileSystemType type, |
@@ -274,6 +288,13 @@ class WEBKIT_STORAGE_BROWSER_EXPORT FileSystemContext |
// the constructor. |
void RegisterBackend(FileSystemBackend* backend); |
+ void DidOpenFileSystemForResolveURL( |
+ const FileSystemURL& url, |
+ const ResolveURLCallback& callback, |
+ const GURL& filesystem_root, |
+ const std::string& filesystem_name, |
+ base::PlatformFileError error); |
+ |
// Returns a FileSystemBackend, used only by test code. |
SandboxFileSystemBackend* sandbox_backend() const { |
return sandbox_backend_.get(); |