W3C home > Mailing lists > Public > xmlschema-dev@w3.org > June 2003

Re: combining enumeration and pattern

From: Jeni Tennison <jeni@jenitennison.com>
Date: Mon, 30 Jun 2003 12:42:44 +0100
Message-ID: <3402770943.20030630124244@jenitennison.com>
To: "Simon Cox" <Simon.Cox@csiro.au>
CC: xmlschema-dev@w3.org, "Clemens Portele" <portele@interactive-instruments.de>

Hi Simon,

> The point about how the facets are combined is the critical one.
> XML Spy agrees with your proposition.
> I was looking for where this is explained in the rec.  
> Can you point out where this behaviour is specified?

In 4.1.4 Simple Definition Validation Rules [1], Validation Rule:
Datatype Valid states:

  A string is datatype-valid with respect to a datatype definition if:

  1 it ·match·es a literal in the ·lexical space· of the datatype,
    determined as follows:
    1.1 if ·pattern· is a member of {facets}, then the string must
        be pattern valid (§;

  2 the value denoted by the literal ·match·ed in the previous step
    is a member of the ·value space· of the datatype, as determined by
    it being Facet Valid (§4.1.4) with respect to each member of
    {facets} (except for ·pattern·).

Clauses 1 and 2 both need to be true for a string to be
datatype-valid, which means that the string has to be *both* pattern
valid and valid with respect to enumeration. Note that clause 2
indicates that other combinations of facets are ANDed rather than


[1] http://www.w3.org/TR/xmlschema-2/#defn-validation-rules

Jeni Tennison
Received on Monday, 30 June 2003 07:42:59 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 23:15:11 UTC