OLD | NEW |
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_MOUNT_POINT_PROVIDER_H_ | 5 #ifndef WEBKIT_FILEAPI_FILE_SYSTEM_MOUNT_POINT_PROVIDER_H_ |
6 #define WEBKIT_FILEAPI_FILE_SYSTEM_MOUNT_POINT_PROVIDER_H_ | 6 #define WEBKIT_FILEAPI_FILE_SYSTEM_MOUNT_POINT_PROVIDER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
133 // |extension_id|. | 133 // |extension_id|. |
134 virtual void GrantFullAccessToExtension(const std::string& extension_id) = 0; | 134 virtual void GrantFullAccessToExtension(const std::string& extension_id) = 0; |
135 // Grants access to |virtual_path| from |origin_url|. | 135 // Grants access to |virtual_path| from |origin_url|. |
136 virtual void GrantFileAccessToExtension( | 136 virtual void GrantFileAccessToExtension( |
137 const std::string& extension_id, | 137 const std::string& extension_id, |
138 const FilePath& virtual_path) = 0; | 138 const FilePath& virtual_path) = 0; |
139 // Revokes file access from extension identified with |extension_id|. | 139 // Revokes file access from extension identified with |extension_id|. |
140 virtual void RevokeAccessForExtension( | 140 virtual void RevokeAccessForExtension( |
141 const std::string& extension_id) = 0; | 141 const std::string& extension_id) = 0; |
142 // Checks if a given |mount_point| already exists. | 142 // Checks if a given |mount_point| already exists. |
143 virtual bool HasMountPoint(const FilePath& mount_point) = 0; | 143 virtual bool HasMountPoint(const FilePath& mount_point) const = 0; |
144 // Adds a new local mount point. | 144 // Adds a new local mount point. |
145 virtual void AddLocalMountPoint(const FilePath& mount_point) = 0; | 145 virtual bool AddLocalMountPoint(const FilePath& mount_point) = 0; |
146 // Adds a new local mount point that will be accessible only by extensions | 146 // Adds a new local mount point that will be accessible only by extensions |
147 // that have been granted full acess for all external file systems. | 147 // that have been granted full acess for all external file systems. |
148 virtual void AddRestrictedLocalMountPoint(const FilePath& mount_point) = 0; | 148 virtual bool AddRestrictedLocalMountPoint(const FilePath& mount_point) = 0; |
149 // Adds a new remote mount point. | 149 // Adds a new remote mount point. |
150 virtual void AddRemoteMountPoint( | 150 virtual bool AddRemoteMountPoint( |
151 const FilePath& mount_point, | 151 const FilePath& mount_point, |
152 RemoteFileSystemProxyInterface* remote_proxy) = 0; | 152 RemoteFileSystemProxyInterface* remote_proxy) = 0; |
153 // Removes a mount point. | 153 // Removes a mount point. |
154 virtual void RemoveMountPoint(const FilePath& mount_point) = 0; | 154 virtual void RemoveMountPoint(const FilePath& mount_point) = 0; |
155 // Gets virtual path by known filesystem path. Returns false when filesystem | 155 // Gets virtual path by known filesystem path. Returns false when filesystem |
156 // path is not exposed by this provider. | 156 // path is not exposed by this provider. |
157 virtual bool GetVirtualPath(const FilePath& file_system_path, | 157 virtual bool GetVirtualPath(const FilePath& file_system_path, |
158 FilePath* virtual_path) = 0; | 158 FilePath* virtual_path) = 0; |
159 }; | 159 }; |
160 | 160 |
161 } // namespace fileapi | 161 } // namespace fileapi |
162 | 162 |
163 #endif // WEBKIT_FILEAPI_FILE_SYSTEM_MOUNT_POINT_PROVIDER_H_ | 163 #endif // WEBKIT_FILEAPI_FILE_SYSTEM_MOUNT_POINT_PROVIDER_H_ |
OLD | NEW |