List ResourceTypes
XML Schema provides a list type allowing more than one item within a single XML element. Items are separated by space.
The following example defines a list element named "Foo" which contains string elements.
<xs:simpleType name="MyListType">
<xs:list itemType="xs:string"/>
</xs:simpleType>
<xs:element name="Foo" type="MyListType">
A valid instantiation of the "Foo" element would be
<Foo>ABC DEF GHI</Foo>
In this example, the "Foo" element contains the three items "ABC", "DEF", and "GHI".
In representation formats other than XML, the space as separator sometimes becomes unhandy. Therefore, a standard representation format for list types is defined for each representation format below.
Query Parameter Representation
In query strings, items of list types are separated by one of the following characters:
<Foo[0]> + "," + <Foo[1]> + "," + <Foo[2]> + "," + …
<Foo[0]> + ";" + <Foo[1]> + ";" + <Foo[2]> + ";" + …
<Foo[0]> + "!" + <Foo[1]> + "!" + <Foo[2]> + "!" + …
The following syntax is introduced as shortcut to represent list types:
<Foo[]>
JSON Representation
List types will be represented as arrays:
[<list[0]>, <list[1]>, <list[2]>, …]