W3C home > Mailing lists > Public > public-webapps@w3.org > October to December 2010

Re: XHR responseArrayBuffer attribute: suggestion to replace "asBlob" with "responseType"

From: Darin Fisher <darin@chromium.org>
Date: Tue, 26 Oct 2010 23:28:40 -0700
Message-ID: <AANLkTinDiHKK-FdBOeQXjzJPL4+VRnDV3BPah6QnsaML@mail.gmail.com>
To: Boris Zbarsky <bzbarsky@mit.edu>
Cc: Anne van Kesteren <annevk@opera.com>, Chris Rogers <crogers@google.com>, Web Applications Working Group WG <public-webapps@w3.org>, Eric Uhrhane <ericu@google.com>, michaeln@google.com, Alexey Proskuryakov <ap@webkit.org>, Chris Marrin <cmarrin@apple.com>, Geoffrey Garen <ggaren@apple.com>, jorlow@google.com
On Tue, Oct 26, 2010 at 5:43 PM, Boris Zbarsky <bzbarsky@mit.edu> wrote:

> On 10/26/10 5:27 AM, Anne van Kesteren wrote:
>
>> Boris, do you see value in the asBlob / responseBlob proposal currently
>> in the draft?
>>
>
> The idea there being that you don't have to have the data in memory at all
> unless the page explicitly asks for it, and then giving the page the option
> of only mapping some of the data into memory?
>

...where "some" may mean none.  you could just get an URL to the Blob, and
shove that into some HTML element for display, or you could use the
FileWriter or FileSaver interfaces to copy the Blob someplace.



>
> I think that's a good idea, yes.
>
> What I'm not quite sure about is why it needs to be a state flag which
> makes it an open-time all-or-nothing decision, other than implementor
> convenience....


I think it's about performance as well as implementor convenience.  If the
implementor knows up front that the data should be stored as a Blob, then
the implementor can write the data to disk without having to waste memory.

-Darin
Received on Wednesday, 27 October 2010 06:29:09 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:41 GMT