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

Side by Side Diff: webkit/fileapi/media/device_media_file_util.h

Issue 10781014: Isolated FS for media devices. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: '' Created 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef WEBKIT_FILEAPI_MEDIA_DEVICE_MEDIA_FILE_UTIL_H_
6 #define WEBKIT_FILEAPI_MEDIA_DEVICE_MEDIA_FILE_UTIL_H_
7
8 #include "base/file_path.h"
9 #include "base/platform_file.h"
10 #include "webkit/fileapi/fileapi_export.h"
11 #include "webkit/fileapi/file_system_file_util.h"
12
13 namespace base {
14 class Time;
15 }
16
17 namespace fileapi {
18
19 class FileSystemOperationContext;
20
21 class FILEAPI_EXPORT_PRIVATE DeviceMediaFileUtil : public FileSystemFileUtil {
22 public:
23 explicit DeviceMediaFileUtil(const FilePath& profile_path);
24 virtual ~DeviceMediaFileUtil() {}
25
26 // FileSystemFileUtil overrides.
27 virtual base::PlatformFileError CreateOrOpen(
28 FileSystemOperationContext* context,
29 const FileSystemURL& url,
30 int file_flags,
31 base::PlatformFile* file_handle,
32 bool* created) OVERRIDE;
33 virtual base::PlatformFileError Close(
34 FileSystemOperationContext* context,
35 base::PlatformFile file) OVERRIDE;
36 virtual base::PlatformFileError EnsureFileExists(
37 FileSystemOperationContext* context,
38 const FileSystemURL& url, bool* created) OVERRIDE;
39 virtual base::PlatformFileError CreateDirectory(
40 FileSystemOperationContext* context,
41 const FileSystemURL& url,
42 bool exclusive,
43 bool recursive) OVERRIDE;
44 virtual base::PlatformFileError GetFileInfo(
45 FileSystemOperationContext* context,
46 const FileSystemURL& url,
47 base::PlatformFileInfo* file_info,
48 FilePath* platform_path) OVERRIDE;
49 virtual AbstractFileEnumerator* CreateFileEnumerator(
50 FileSystemOperationContext* context,
51 const FileSystemURL& root_url,
52 bool recursive) OVERRIDE;
53 virtual PlatformFileError GetLocalFilePath(
54 FileSystemOperationContext* context,
55 const FileSystemURL& file_system_url,
56 FilePath* local_file_path) OVERRIDE;
57 virtual base::PlatformFileError Touch(
58 FileSystemOperationContext* context,
59 const FileSystemURL& url,
60 const base::Time& last_access_time,
61 const base::Time& last_modified_time) OVERRIDE;
62 virtual base::PlatformFileError Truncate(
63 FileSystemOperationContext* context,
64 const FileSystemURL& url,
65 int64 length) OVERRIDE;
66 virtual bool PathExists(
67 FileSystemOperationContext* context,
68 const FileSystemURL& url) OVERRIDE;
69 virtual bool DirectoryExists(
70 FileSystemOperationContext* context,
71 const FileSystemURL& url) OVERRIDE;
72 virtual bool IsDirectoryEmpty(
73 FileSystemOperationContext* context,
74 const FileSystemURL& url) OVERRIDE;
75 virtual base::PlatformFileError CopyOrMoveFile(
76 FileSystemOperationContext* context,
77 const FileSystemURL& src_url,
78 const FileSystemURL& dest_url,
79 bool copy) OVERRIDE;
80 virtual base::PlatformFileError CopyInForeignFile(
81 FileSystemOperationContext* context,
82 const FilePath& src_file_path,
83 const FileSystemURL& dest_url) OVERRIDE;
84 virtual base::PlatformFileError DeleteFile(
85 FileSystemOperationContext* context,
86 const FileSystemURL& url) OVERRIDE;
87 virtual base::PlatformFileError DeleteSingleDirectory(
88 FileSystemOperationContext* context,
89 const FileSystemURL& url) OVERRIDE;
90 virtual scoped_refptr<webkit_blob::ShareableFileReference>
91 CreateSnapshotFile(FileSystemOperationContext* context,
92 const FileSystemURL& url,
93 base::PlatformFileError* result,
94 base::PlatformFileInfo* file_info,
95 FilePath* platform_path) OVERRIDE;
96
97 private:
98 // Profile path
99 const FilePath profile_path_;
100
101 DISALLOW_COPY_AND_ASSIGN(DeviceMediaFileUtil);
102 };
103
104 } // namespace fileapi
105
106 #endif // WEBKIT_FILEAPI_MEDIA_DEVICE_MEDIA_FILE_UTIL_H_
OLDNEW
« no previous file with comments | « webkit/fileapi/isolated_mount_point_provider.cc ('k') | webkit/fileapi/media/device_media_file_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698