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

Unified Diff: ppapi/api/ppb_file_mapping.idl

Issue 69663002: PPAPI: Implement PPB_FileMapping on POSIX (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rough patch. Starting testing. Created 6 years, 11 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_file_io_dev.idl ('k') | ppapi/c/dev/ppb_file_io_dev.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/api/ppb_file_mapping.idl
diff --git a/ppapi/api/dev/ppb_file_io_dev.idl b/ppapi/api/ppb_file_mapping.idl
similarity index 84%
rename from ppapi/api/dev/ppb_file_io_dev.idl
rename to ppapi/api/ppb_file_mapping.idl
index 82a645211168da8b53a6625fdaf8af28d6b80845..c325c4a392d776ee7886541fb17b7d37ca49b19e 100644
--- a/ppapi/api/dev/ppb_file_io_dev.idl
+++ b/ppapi/api/ppb_file_mapping.idl
@@ -9,9 +9,10 @@
* stable in the future. For now, they can be used only in plugins with DEV
* permissions.
*/
+[generate_thunk]
label Chrome {
- M31 = 0.1
+ [channel=dev] M34 = 0.1
};
/**
@@ -19,7 +20,7 @@ label Chrome {
* file mapping. These should be used in a uint32_t bitfield.
*/
[assert_size(4)]
- enum PP_FileMapProtection {
+enum PP_FileMapProtection {
/** Requests read access to the mapped address. */
PP_FILEMAPPROTECTION_READ = 1u << 0,
@@ -31,7 +32,7 @@ label Chrome {
* The PP_FileMapFlags contain flag values for use with Map().
*/
[assert_size(4)]
- enum PP_FileMapFlags {
+enum PP_FileMapFlags {
/**
* Requests a shared mapping. If this flag is set, changes written to the
* memory region will be reflected in the underlying file and will thus
@@ -56,12 +57,13 @@ label Chrome {
};
/**
- * PPB_FileIO_Dev contains functions that are usable with PPB_FileIO resources
+ * PPB_FileMapping contains functions that are usable with PPB_FileIO resources
* but aren't yet considered stable yet and thus are not supported for general
* NaCl or PNaCl apps yet. Features here are being tested and refined for
* possible future inclusion in (stable) PPB_FileIO.
*/
-interface PPB_FileIO_Dev {
+[singleton]
+interface PPB_FileMapping {
/**
* Map() maps the contents from an offset of the file into memory.
*
@@ -87,7 +89,9 @@ interface PPB_FileIO_Dev {
*
* @return An int32_t containing an error code from <code>pp_errors.h</code>.
*/
- int32_t Map([in] PP_Resource file_io,
+[singleton]
+ int32_t Map([in] PP_Instance instance,
+ [in] PP_Resource file_io,
[in] int64_t length,
[in] uint32_t map_protection,
[in] uint32_t map_flags,
@@ -96,21 +100,21 @@ interface PPB_FileIO_Dev {
[in] PP_CompletionCallback callback);
/**
- * Unmap() deletes the mapping of the specified address address to a
- * file io. The specified address must have been retrieved with
- * Map().
- * @param[in] file_io A PP_Resource corresponding to a file.
+ * Unmap() deletes the mapping of the specified address. The specified
+ * address must have been retrieved with Map().
+ * @param[in] instance A <code>PP_Instance</code> identifying the instance.
* @param[in] address The starting address of the address in memory to
* be unmapped.
* @param[in] length The length of the region to unmap.
*/
- void Unmap(PP_Resource file_io, mem_t address, int64_t length);
+ void Unmap(PP_Instance file_io, mem_t address, int64_t length);
/**
* GetMapPageSize() returns the size of pages that Map() uses. Returns 0 on
* failure.
+ * @param[in] instance A <code>PP_Instance</code> identifying the instance.
*/
[on_failure=0]
- int64_t GetMapPageSize(PP_Resource file_io);
+ int64_t GetMapPageSize(PP_Instance file_io);
};
« no previous file with comments | « ppapi/api/dev/ppb_file_io_dev.idl ('k') | ppapi/c/dev/ppb_file_io_dev.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698