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

Unified Diff: ppapi/api/ppb_directory_reader.idl

Issue 14419003: PPAPI: Move PPB_DirectoryReader_Dev to stable (won't commit) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review fix Created 7 years, 8 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
« no previous file with comments | « ppapi/api/dev/ppb_directory_reader_dev.idl ('k') | ppapi/c/dev/ppb_directory_reader_dev.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/api/ppb_directory_reader.idl
diff --git a/ppapi/api/ppb_directory_reader.idl b/ppapi/api/ppb_directory_reader.idl
new file mode 100644
index 0000000000000000000000000000000000000000..36484cb783e4a77d354e75b7e2c38d48304e2fc8
--- /dev/null
+++ b/ppapi/api/ppb_directory_reader.idl
@@ -0,0 +1,59 @@
+/* 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.
+ */
+
+/**
+ * This file defines the <code>PPB_DirectoryReader</code> interface.
+ */
+
+label Chrome {
+ M28 = 1.0
+};
+
+/**
+ * The <code>PP_DirectoryEntry</code> struct represents information about a
+ * directory entry.
+ */
+[assert_size(8)]
+struct PP_DirectoryEntry {
+ PP_Resource file_ref;
+ PP_FileType file_type;
+};
+
+/**
+ * The <code>PPB_DirectoryReader</code> interface provides a function to read
+ * entries in a directory.
+ */
+interface PPB_DirectoryReader {
+ /**
+ * Creates a DirectoryReader for the given directory. Upon success, the
+ * corresponding directory is classified as "in use" by the resulting
+ * DirectoryReader object until such time as the DirectoryReader object is
+ * destroyed.
+ */
+ PP_Resource Create([in] PP_Resource directory_ref);
+
+ /**
+ * Returns PP_TRUE if the given resource is a DirectoryReader. Returns
+ * PP_FALSE if the resource is invalid or some type other than a
+ * DirectoryReader.
+ */
+ PP_Bool IsDirectoryReader([in] PP_Resource resource);
+
+ /**
+ * Reads all entries in the directory.
+ *
+ * @param[in] directory_reader A <code>PP_Resource</code>
+ * corresponding to a directory reader resource.
+ * @param[in] output An output array which will receive
+ * <code>PP_DirectoryEntry</code> objects on success.
+ * @param[in] callback A <code>PP_CompletionCallback</code> to run on
+ * completion.
+ *
+ * @return An error code from <code>pp_errors.h</code>.
+ */
+ int32_t ReadEntries([in] PP_Resource directory_reader,
+ [in] PP_ArrayOutput output,
+ [in] PP_CompletionCallback callback);
+};
« no previous file with comments | « ppapi/api/dev/ppb_directory_reader_dev.idl ('k') | ppapi/c/dev/ppb_directory_reader_dev.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698