Re: Enumeration syntax

From
<>
Date
2001-05-20T21:30:33+00:00
ID
Thread
Re: Enumeration syntax
> Another advantage of the option b syntax for enumerations:
> 
> <choice>
>   <value>foo</value>
>   <value>bar</value>
> </choice>
> 
> is that combine='choice' can be used to add values to an enumeration.

This looks like a good point, although it is also possible to use
@combine to add values to an enumeration in case of other options.

For example,

<choice>
  <enumeration type="xsd:token">
    <value>foo</value>
    <value>bar</value>
  </enumeration>
  
  <enumeration type="xsd:token">
    <value>additional</value>
  </enumeration>
</choice>


Another advantage of the option (b) is that <value> element is very
close to the current <string> element. So it will make migration from
TREX easier.

Maybe we can even keep the tag name as <string>. I think

<string type="xsd:integer">  52  </string>

makes sense.



--
Kohsuke KAWAGUCHI                          +1 650 786 0721
Sun Microsystems