[WebIDL] Trying to understand IndexGetter/NameGetter

In section 4.4.2 of WebIDL, there is the following language:

   As soon as a name N begins being able to be used to index
   the host object, a property called the corresponding named
   property  MUST be created on the host object...

IndexGetter has similar verbiage.  I'm really not clear on this "begins 
being able to be used" thing.  Is that something the interface needs to 
define?

In particular, consider using IndexGetter for NodeList.  At what point 
can "10000" be used to index the nodelist?  Is it as soon as the 
nodelist is created?  Once the length is > 10000?  Something else?

In particular, the interaction with existing properties interests me. 
If I set document.links[5] while the document has 3 links and then I add 
3 more links, what is the value of document.links[5]?  What if I had 6 
links to start with?

-Boris

Received on Wednesday, 30 September 2009 14:32:39 UTC