Index: webkit/fileapi/mount_points.h |
diff --git a/webkit/fileapi/mount_points.h b/webkit/fileapi/mount_points.h |
index 7fcc2314c8462d72112a09904a27260b37514a8f..bcb2995bad60c0c7a2dc87e7d336825d6a32e50b 100644 |
--- a/webkit/fileapi/mount_points.h |
+++ b/webkit/fileapi/mount_points.h |
@@ -88,6 +88,19 @@ class WEBKIT_STORAGE_EXPORT MountPoints { |
FileSystemType* type, |
base::FilePath* path) const = 0; |
+ // Converts a path on a registered file system to virtual path relative to the |
+ // file system root. E.g. if 'Downloads' file system is mapped to |
+ // '/usr/local/home/Downloads', and |absolute| path is set to |
+ // '/usr/local/home/Downloads/foo', the method will set |virtual_path| to |
+ // 'Downloads/foo'. |
+ // Returns false if the path cannot be resolved (e.g. if the path is not |
+ // part of any registered filesystem or MountPoints implementation does not |
+ // support conversion from full to virtual path). |
+ // |
+ // Returned virtual_path will have normalized path separators. |
+ virtual bool GetVirtualPath(const base::FilePath& full_path, |
+ base::FilePath* virtual_path) const = 0; |
+ |
private: |
DISALLOW_COPY_AND_ASSIGN(MountPoints); |
}; |