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

Unified Diff: webkit/fileapi/media/media_device_interface.h

Issue 10781014: Isolated FS for media devices. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix tests Created 8 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: webkit/fileapi/media/media_device_interface.h
diff --git a/webkit/fileapi/media/media_device_interface.h b/webkit/fileapi/media/media_device_interface.h
new file mode 100644
index 0000000000000000000000000000000000000000..574355d765240ff20361f2b98a1564785911788f
--- /dev/null
+++ b/webkit/fileapi/media/media_device_interface.h
@@ -0,0 +1,42 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef WEBKIT_FILEAPI_MEDIA_DEVICE_INTERFACE_H_
+#define WEBKIT_FILEAPI_MEDIA_DEVICE_INTERFACE_H_
+
+#include "base/file_path.h"
+#include "base/platform_file.h"
+#include "base/timer.h"
+#include "webkit/fileapi/file_system_file_util.h"
+
+namespace base {
+struct PlatformFileInfo;
+class Time;
+}
+
+namespace fileapi {
+
+using base::PlatformFileError;
+using base::PlatformFileInfo;
+using base::Time;
+
+// Helper interface to support media device isolated file system operations.
+class MediaDeviceInterface {
+ public:
+ virtual PlatformFileError GetFileInfo(const FilePath& file_path,
+ PlatformFileInfo* file_info) = 0;
+ virtual FileSystemFileUtil::AbstractFileEnumerator* CreateFileEnumerator(
+ const FilePath& root,
+ bool recursive) = 0;
+ virtual PlatformFileError Touch(const FilePath& file_path,
+ const Time& last_access_time,
+ const Time& last_modified_time) = 0;
+ virtual bool PathExists(const FilePath& file_path) = 0;
+ virtual bool DirectoryExists(const FilePath& file_path) = 0;
+ virtual bool IsDirectoryEmpty(const FilePath& file_path) = 0;
+};
+
+} // namespace fileapi
+
+#endif // WEBKIT_FILEAPI_MEDIA_DEVICE_INTERFACE_H_

Powered by Google App Engine
This is Rietveld 408576698