W3C home > Mailing lists > Public > public-script-coord@w3.org > July to September 2013

Re: Maplike

From: Chris Wilson <cwilso@google.com>
Date: Fri, 13 Sep 2013 13:38:56 -0700
Message-ID: <CAJK2wqUiKsf3xuxGF2DtdQr4GOyAtHTDXc1UGPRBECCyikMmtw@mail.gmail.com>
To: "Tab Atkins Jr." <jackalmage@gmail.com>
Cc: "public-script-coord@w3.org" <public-script-coord@w3.org>
On Fri, Sep 13, 2013 at 1:10 PM, Tab Atkins Jr. <jackalmage@gmail.com>wrote:

> On Fri, Sep 13, 2013 at 9:10 AM, Chris Wilson <cwilso@google.com> wrote:
> > First comment - the missing bits defining iterators in
> > http://dev.w3.org/2006/webapi/WebIDL/#es-map-members is, of course, a
> little
> > problematic, because I'll have to make something up.  Tab mentioned the
> ES
> > spec has these defined; should I go there for the definitions?
>
> You don't have to define anything yourself - the iteration will just
> use the map entries that you already have to define.
>

Yeah, I didn't mean I'd have to make it up in the IDL - I'll have to make
some assumptions about how they work to show examples. :)


> > My hope is that it's feasible to say that any readonly attribute whose
> value
> > is a MapClass interface is automatically readonly with respect to the map
> > itself, such that set/clear/delete all throw or silently fail or
> something.
>
> I thought this was reasonable earlier, but I've found that it's not -
> for example, for the Font Load Events API, I believe I want
> document.fonts to be readonly, so people cant' replace the object, but
> still allow additions/deletions.
>

Hmm, yeah, I can see that.


> Still, though some easy way to indicate that something is a "frozen"
> Map/Set would be very appreciated.
>

+1.  :)

-C
Received on Friday, 13 September 2013 20:39:23 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:37:50 UTC