W3C home > Mailing lists > Public > public-webapps@w3.org > July to September 2009

Re: File API Feedback

From: Jonas Sicking <jonas@sicking.cc>
Date: Mon, 6 Jul 2009 13:41:16 -0700
Message-ID: <63df84f0907061341u39cb50efh696a592a99b4a099@mail.gmail.com>
To: Garrett Smith <dhtmlkitchen@gmail.com>
Cc: arun@mozilla.com, Boris Zbarsky <bzbarsky@mit.edu>, Ian Hickson <ian@hixie.ch>, Anne van Kesteren <annevk@opera.com>, WebApps WG <public-webapps@w3.org>
On Mon, Jul 6, 2009 at 1:38 PM, Jonas Sicking<jonas@sicking.cc> wrote:
> So what if you're reading two parts of the file and want different
> callbacks. Say for example that you're reading data out of a video
> file and you want to read both the index of the video to see how long
> it is, as well as read read the first frame in order to display a
> preview. Once we have an API for reading ranges of a file, you'd do:
>
> file.getDataAtRange(0, 1024, indexHandler, genericError);
> file.getDataAtRange(4711, 5735, indexHandler, genericError);
>
> (the example assumes that the index is located at byte 0, and the
> first video frame is located at byte 4711).
>
> How would you do that using the API you are proposing?

Oops, sorry, there's a copy-n-paste error in the above. It should read:

file.getDataAtRange(0, 1024, indexHandler, genericError);
file.getDataAtRange(4711, 5735, showFrameHandler, genericError);

/ Jonas
Received on Monday, 6 July 2009 20:42:13 GMT

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