Re: fixed property of the min/max/Inclusive/Exclusive facet

Jeff Rafter wrote:

> > I'd like to ask once more with some changes (min -> max).
> >
> > The following is illegal since fixed = 'true' ?
> >
> > <simpleType name='myType2'>
> > <restriction>
> > <simpleType>
> > <restriction base='integer'>
> > <maxExclusive value='11' fixed='true'/>
> > </restriction>
> > </simpleType>
> > <maxInclusive value='10'/>
> > </restriction>
> > </simpleType>
>
> Correct-- it is illegal [1].
>
> "If {fixed} is true, then types for which the current type is the {base type
> definition} cannot specify a value for maxInclusive other than {value}. "
>
> [1] http://www.w3.org/TR/xmlschema-2/#dt-maxInclusive

I don't think this rule can be applied to the above example. The above [1] only
applies if both facets had been maxInclusive. However, in the above example the
base type has maxExlusive = "11" and then the derived type has
maxInclusive="10". I'm not sure where this is in the spec or if it's allowed to
redefine maxInclusive although maxExclusive is set to fixed. I've found this in
the definition for maxExclusive [1]:

"It is an _error_ for both _maxInclusive_ and _maxExclusive_ to be specified in
the same derivation step of a datatype definition."

In the above example maxInclusive and maxExclusive are not in the same
derivation step so I guess it's valid (then again maybe not...)

Cheers,
/Eddie
[1] http://www.w3.org/TR/xmlschema-2/#maxExclusive-coss

Received on Thursday, 7 June 2001 02:47:29 UTC