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

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

Issue 10914188: Added PlatformFileError param to FileSystemMountPointProvider::CreateFileSystemOperation function. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 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_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 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 // Returns the specialized FileSystemFileUtil for this mount point. 70 // Returns the specialized FileSystemFileUtil for this mount point.
71 virtual FileSystemFileUtil* GetFileUtil(FileSystemType type) = 0; 71 virtual FileSystemFileUtil* GetFileUtil(FileSystemType type) = 0;
72 72
73 // Returns file path we should use to check access permissions for 73 // Returns file path we should use to check access permissions for
74 // |virtual_path|. 74 // |virtual_path|.
75 virtual FilePath GetPathForPermissionsCheck(const FilePath& virtual_path) 75 virtual FilePath GetPathForPermissionsCheck(const FilePath& virtual_path)
76 const = 0; 76 const = 0;
77 77
78 // Returns a new instance of the specialized FileSystemOperation for this 78 // Returns a new instance of the specialized FileSystemOperation for this
79 // mount point based on the given triplet of |origin_url|, |file_system_type| 79 // mount point based on the given triplet of |origin_url|, |file_system_type|
80 // and |virtual_path|. 80 // and |virtual_path|. On failure to create a file system operation, set
81 // |error_code| correspondingly.
81 // This method is usually dispatched by 82 // This method is usually dispatched by
82 // FileSystemContext::CreateFileSystemOperation. 83 // FileSystemContext::CreateFileSystemOperation.
83 virtual FileSystemOperation* CreateFileSystemOperation( 84 virtual FileSystemOperation* CreateFileSystemOperation(
84 const FileSystemURL& url, 85 const FileSystemURL& url,
85 FileSystemContext* context) const = 0; 86 FileSystemContext* context,
87 base::PlatformFileError* error_code) const = 0;
86 88
87 // Creates a new file stream reader for a given filesystem URL |url| with an 89 // Creates a new file stream reader for a given filesystem URL |url| with an
88 // offset |offset|. 90 // offset |offset|.
89 // The returned object must be owned and managed by the caller. 91 // The returned object must be owned and managed by the caller.
90 // This method itself does *not* check if the given path exists and is a 92 // This method itself does *not* check if the given path exists and is a
91 // regular file. 93 // regular file.
92 virtual webkit_blob::FileStreamReader* CreateFileStreamReader( 94 virtual webkit_blob::FileStreamReader* CreateFileStreamReader(
93 const FileSystemURL& url, 95 const FileSystemURL& url,
94 int64 offset, 96 int64 offset,
95 FileSystemContext* context) const = 0; 97 FileSystemContext* context) const = 0;
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
146 virtual void RemoveMountPoint(const FilePath& mount_point) = 0; 148 virtual void RemoveMountPoint(const FilePath& mount_point) = 0;
147 // Gets virtual path by known filesystem path. Returns false when filesystem 149 // Gets virtual path by known filesystem path. Returns false when filesystem
148 // path is not exposed by this provider. 150 // path is not exposed by this provider.
149 virtual bool GetVirtualPath(const FilePath& file_system_path, 151 virtual bool GetVirtualPath(const FilePath& file_system_path,
150 FilePath* virtual_path) = 0; 152 FilePath* virtual_path) = 0;
151 }; 153 };
152 154
153 } // namespace fileapi 155 } // namespace fileapi
154 156
155 #endif // WEBKIT_FILEAPI_FILE_SYSTEM_MOUNT_POINT_PROVIDER_H_ 157 #endif // WEBKIT_FILEAPI_FILE_SYSTEM_MOUNT_POINT_PROVIDER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698