spec/Overview.html 1.1828 2658 Define what is actually enumerated in co

Define what is actually enumerated in collections, as per WebIDL.
(whatwg r2658)

item(index)
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1828.html#dom-htmlformcontrolscollection-item
HTMLOptionsCollection
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1828.html#htmloptionscollection-0
HTMLCollection
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1828.html#htmlcollection-0
namedItem(key)
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1828.html#dom-htmlcollection-nameditem
item(index)
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1828.html#dom-htmlcollection-item
namedItem(key)
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1828.html#dom-htmloptionscollection-nameditem
item(index)
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1828.html#dom-htmloptionscollection-item
length
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1828.html#dom-htmlformcontrolscollection-length
length
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1828.html#dom-htmloptionscollection-length
HTMLFormControlsCollection
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1828.html#htmlformcontrolscollection-0
length
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1828.html#dom-htmlcollection-length
namedItem(key)
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1828.html#dom-htmlformcontrolscollection-nameditem

http://people.w3.org/mike/diffs/html5/spec/Overview.diff.html
http://dev.w3.org/cvsweb/html5/spec/Overview.html?r1=1.1827&r2=1.1828&f=h
http://html5.org/tools/web-apps-tracker?from=2657&to=2658

===================================================================
RCS file: /sources/public/html5/spec/Overview.html,v
retrieving revision 1.1827
retrieving revision 1.1828
diff -u -d -r1.1827 -r1.1828
--- Overview.html 13 Jan 2009 11:56:37 -0000 1.1827
+++ Overview.html 13 Jan 2009 12:11:50 -0000 1.1828
@@ -4477,10 +4477,22 @@
   readonly attribute unsigned long <a href=#dom-htmlcollection-length title=dom-HTMLCollection-length>length</a>;
   [IndexGetter] Element <a href=#dom-htmlcollection-item title=dom-HTMLCollection-item>item</a>(in unsigned long index);
   [NameGetter] Element <a href=#dom-htmlcollection-nameditem title=dom-HTMLCollection-namedItem>namedItem</a>(in DOMString name);
-};</pre><p>The <dfn id=dom-htmlcollection-length title=dom-HTMLCollection-length><code>length</code></dfn>
+};</pre><p>The object's <span>indices of the supported indexed
+  properties</span> are the numbers in the range zero to one less than
+  the number of nodes <a href=#represented-by-the-collection>represented by the collection</a>. If
+  there are no such elements, then there are no supported
+  properties.<p>The <dfn id=dom-htmlcollection-length title=dom-HTMLCollection-length><code>length</code></dfn>
   attribute must return the number of nodes <a href=#represented-by-the-collection>represented by the
   collection</a>.<p>The <dfn id=dom-htmlcollection-item title=dom-HTMLCollection-item><code>item(<var title="">index</var>)</code></dfn> method must return the <var title="">index</var>th node in the collection. If there is no <var title="">index</var>th node in the collection, then the method must
-  return null.<p>The <dfn id=dom-htmlcollection-nameditem title=dom-HTMLCollection-namedItem><code>namedItem(<var title="">key</var>)</code></dfn> method must return the first node
+  return null.<p>The <span>names of the supported named properties</span> consist
+  of the values of the <code title="">name</code> attributes of each
+  <code><a href=#the-a-element>a</a></code>, <code><a href=#the-applet-element>applet</a></code>, <code><a href=#the-area-element>area</a></code>,
+  <code><a href=#the-embed-element>embed</a></code>, <code><a href=#the-form-element>form</a></code>, <code>frame</code>,
+  <code>frameset</code>, <code><a href=#the-iframe-element>iframe</a></code>, <code><a href=#the-img-element>img</a></code>, and
+  <code><a href=#the-object-element>object</a></code> element <a href=#represented-by-the-collection>represented by the
+  collection</a> with a <code title="">name</code> attribute, plus
+  the list of IDs that the elements <a href=#represented-by-the-collection>represented by the
+  collection</a> have.<p>The <dfn id=dom-htmlcollection-nameditem title=dom-HTMLCollection-namedItem><code>namedItem(<var title="">key</var>)</code></dfn> method must return the first node
   in the collection that matches the following requirements:<ul><li>It is an <code><a href=#the-a-element>a</a></code>, <code><a href=#the-applet-element>applet</a></code>,
    <code><a href=#the-area-element>area</a></code>, <code><a href=#the-embed-element>embed</a></code>, <code><a href=#the-form-element>form</a></code>,
    <code>frame</code>, <code>frameset</code>, <code><a href=#the-iframe-element>iframe</a></code>,
@@ -4497,10 +4509,16 @@
   readonly attribute unsigned long <a href=#dom-htmlformcontrolscollection-length title=dom-HTMLFormControlsCollection-length>length</a>;
   [IndexGetter] <a href=#htmlelement>HTMLElement</a> <a href=#dom-htmlformcontrolscollection-item title=dom-HTMLFormControlsCollection-item>item</a>(in unsigned long index);
   [NameGetter] Object <a href=#dom-htmlformcontrolscollection-nameditem title=dom-HTMLFormControlsCollection-namedItem>namedItem</a>(in DOMString name);
-};</pre><p>The <dfn id=dom-htmlformcontrolscollection-length title=dom-HTMLFormControlsCollection-length><code>length</code></dfn>
+};</pre><p>The object's <span>indices of the supported indexed
+  properties</span> are the numbers in the range zero to one less than
+  the number of nodes <a href=#represented-by-the-collection>represented by the collection</a>. If
+  there are no such elements, then there are no supported
+  properties.<p>The <dfn id=dom-htmlformcontrolscollection-length title=dom-HTMLFormControlsCollection-length><code>length</code></dfn>
   attribute must return the number of nodes <a href=#represented-by-the-collection>represented by the
   collection</a>.<p>The <dfn id=dom-htmlformcontrolscollection-item title=dom-HTMLFormControlsCollection-item><code>item(<var title="">index</var>)</code></dfn> method must return the <var title="">index</var>th node in the collection. If there is no <var title="">index</var>th node in the collection, then the method must
-  return null.<p>The <dfn id=dom-htmlformcontrolscollection-nameditem title=dom-HTMLFormControlsCollection-namedItem><code>namedItem(<var title="">key</var>)</code></dfn>
+  return null.<p>The <span>names of the supported named properties</span> consist
+  of the values of all the <code title=attr-id><a href=#the-id-attribute>id</a></code> and <code title=attr-fe-name><a href=#attr-fe-name>name</a></code> attributes of all the elements
+  <a href=#represented-by-the-collection>represented by the collection</a>.<p>The <dfn id=dom-htmlformcontrolscollection-nameditem title=dom-HTMLFormControlsCollection-namedItem><code>namedItem(<var title="">key</var>)</code></dfn>
   method must act according to the following algorithm:
 
   <ol><li>If, at the time the method is called, there is exactly one node
@@ -4532,7 +4550,11 @@
   void <a href=#dom-htmloptionscollection-add title=dom-HTMLOptionsCollection-add>add</a>(in <a href=#htmlelement>HTMLElement</a> element, in <a href=#htmlelement>HTMLElement</a> before);
   void <a href=#dom-htmloptionscollection-add title=dom-HTMLOptionsCollection-add>add</a>(in <a href=#htmlelement>HTMLElement</a> element, in long before);
   void <a href=#dom-htmloptionscollection-remove title=dom-HTMLOptionsCollection-remove>remove</a>(in long index);
-};</pre><p>On getting, the <dfn id=dom-htmloptionscollection-length title=dom-HTMLOptionsCollection-length><code>length</code></dfn>
+};</pre><p>The object's <span>indices of the supported indexed
+  properties</span> are the numbers in the range zero to one less than
+  the number of nodes <a href=#represented-by-the-collection>represented by the collection</a>. If
+  there are no such elements, then there are no supported
+  properties.<p>On getting, the <dfn id=dom-htmloptionscollection-length title=dom-HTMLOptionsCollection-length><code>length</code></dfn>
   attribute must return the number of nodes <a href=#represented-by-the-collection>represented by the
   collection</a>.<p>On setting, the behavior depends on whether the new value is
   equal to, greater than, or less than the number of nodes
@@ -4549,7 +4571,9 @@
   or adds any <code><a href=#the-optgroup-element>optgroup</a></code> elements, and never adds new
   children to existing <code><a href=#the-optgroup-element>optgroup</a></code> elements (though it can
   remove children from them).<p>The <dfn id=dom-htmloptionscollection-item title=dom-HTMLOptionsCollection-item><code>item(<var title="">index</var>)</code></dfn> method must return the <var title="">index</var>th node in the collection. If there is no <var title="">index</var>th node in the collection, then the method must
-  return null.<p>The <dfn id=dom-htmloptionscollection-nameditem title=dom-HTMLOptionsCollection-namedItem><code>namedItem(<var title="">key</var>)</code></dfn>
+  return null.<p>The <span>names of the supported named properties</span> consist
+  of the values of all the <code title=attr-id><a href=#the-id-attribute>id</a></code> and <code title=attr-option-name>name</code> attributes of all the elements
+  <a href=#represented-by-the-collection>represented by the collection</a>.<p>The <dfn id=dom-htmloptionscollection-nameditem title=dom-HTMLOptionsCollection-namedItem><code>namedItem(<var title="">key</var>)</code></dfn>
   method must act according to the following algorithm:
 
   <ol><li>If, at the time the method is called, there is exactly one node

Received on Tuesday, 13 January 2009 12:15:14 UTC