| Index: ppapi/api/ppb_url_loader.idl
|
| diff --git a/ppapi/api/ppb_url_loader.idl b/ppapi/api/ppb_url_loader.idl
|
| index ad311009e67c7e1caed6e6ce58c9a152e42e00ff..03463a6e2f058ef61c5329cc7ba9100befdb78f8 100644
|
| --- a/ppapi/api/ppb_url_loader.idl
|
| +++ b/ppapi/api/ppb_url_loader.idl
|
| @@ -9,7 +9,8 @@
|
| */
|
|
|
| label Chrome {
|
| - M14 = 1.0
|
| + M14 = 1.0,
|
| + M26 = 1.1
|
| };
|
|
|
| /**
|
| @@ -163,6 +164,9 @@ interface PPB_URLLoader {
|
| * buffer must be large enough to hold the specified number of bytes to read.
|
| * This function might perform a partial read.
|
| *
|
| + * ReadResponseBodyToArray() is preferred to ReadResponseBody() when doing
|
| + * asynchronous operations.
|
| + *
|
| * @param[in] loader A <code>PP_Resource</code> corresponding to a
|
| * <code>URLLoader</code>.
|
| * @param[in,out] buffer A pointer to the buffer for the response body.
|
| @@ -217,5 +221,29 @@ interface PPB_URLLoader {
|
| */
|
| void Close(
|
| [in] PP_Resource loader);
|
| +
|
| + /**
|
| + * ReadResponseBody() is used to read the response body. The size of the
|
| + * buffer must be large enough to hold the specified number of bytes to read.
|
| + * This function might perform a partial read.
|
| + *
|
| + * @param[in] loader A <code>PP_Resource</code> corresponding to a
|
| + * <code>URLLoader</code>.
|
| + * @param[in,out] output A <code>PP_ArrayOutput</code> to hold the output.
|
| + * @param[in] max_read_length The number of bytes to read.
|
| + * @param[in] callback A <code>PP_CompletionCallback</code> to run on
|
| + * asynchronous completion. The callback will run if the bytes (full or
|
| + * partial) are read or an error occurs asynchronously. This callback will
|
| + * run only if this function returns <code>PP_OK_COMPLETIONPENDING</code>.
|
| + *
|
| + * @return An int32_t containing the number of bytes read or an error code
|
| + * from <code>pp_errors.h</code>.
|
| + */
|
| + [version = 1.1]
|
| + int32_t ReadResponseBodyToArray(
|
| + [in] PP_Resource loader,
|
| + [in] int32_t max_read_length,
|
| + [inout] PP_ArrayOutput output,
|
| + [in] PP_CompletionCallback callback);
|
| };
|
|
|
|
|