[whatwg] HTML5 Offline Web Applications

Michael Nordman michaeln at google.com
Wed Oct 8 11:51:30 PDT 2008


> Here's the thing i'm trying to avoid in section 5.7.6 where it
> discusses the add(url) method.
> ...
> 8. "Wait for there to be no running scripts, or at least no running
> scripts that can reach an ApplicationCache object associated with the
> application cache with which this ApplicationCache object is
> associated."
> ...
> The same system-wide synchronization has to be applied for the
> remove(url) method.
>
> The utility of the .length and .item(indx) method could be provided in
> such a way that this awkwardness could be avoided.
>
> Some ideas...
> bool contains(url);
> string[] getItems();

Another idea, getItems() wouldn't work well with very large collections

void forEachItem(callback);  // iteration terminates if the callback
returns false or throws



More information about the whatwg mailing list