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

[WebIDL] Sequences and arrays

From: Cameron McCormack <cam@mcc.id.au>
Date: Tue, 7 Jul 2009 17:44:37 +1000
To: public-webapps@w3.org
Message-ID: <20090707074437.GA19724@arc.mcc.id.au>
Hello WG.

I’ve finally fixed up sequences in Web IDL, and also added an array
type.  The difference is that:

  * sequences are effectively pass-by-value, represented by a JS Array
    or a Java array object, and
  * arrays are pass-by-reference, represented by a JS host object that
    acts similarly to an Array (including having Array.prototype in its
    prototype chain, but not supporting sparse arrays) or by a Java
    object that implements an interface defined in the spec that allows
    access to elements and the array length.

JS Array objects can also be passed to host objects expecting an array,
but the Array object will be converted into the special host object.




Comments welcome.

Cameron McCormack ≝ http://mcc.id.au/
Received on Tuesday, 7 July 2009 07:45:22 UTC

This archive was generated by hypermail 2.3.1 : Friday, 27 October 2017 07:26:17 UTC