W3C home > Mailing lists > Public > www-xml-schema-comments@w3.org > October to December 2003

RE: E2-35: min/maxLength after length?

From: Ashok Malhotra <ashokma@microsoft.com>
Date: Mon, 10 Nov 2003 14:17:22 -0800
Message-ID: <EDB607C8AC991F40BE646533A1A673E8923C08@RED-MSG-42.redmond.corp.microsoft.com>
To: "Sandy Gao" <sandygao@ca.ibm.com>, <www-xml-schema-comments@w3.org>

We have had some discussions in the past about whether specifying a
value for the length facet should be made a shorthand for specifying a
and a maxLength with the same value.  Unfortunately, I cannot find a
requirement in the Requirements Document for this.

The proposal would be:

- Remove the length facet.
- Make setting the length facet syntactic sugar for setting the
minLength and maxLength facets to the same value.

All the best, Ashok

-----Original Message-----
From: www-xml-schema-comments-request@w3.org
[mailto:www-xml-schema-comments-request@w3.org] On Behalf Of Sandy Gao
Sent: Monday, November 10, 2003 1:11 PM
To: www-xml-schema-comments@w3.org
Subject: E2-35: min/maxLength after length?

E2-35 [1] makes the following declarations valid:

<xs:simpleType name="st1">
  <xs:restriction base="xs:string">
    <xs:length value="5"/>

<xs:simpleType name="st2">
  <xs:restriction base="st1">
    <xs:minlength value="2"/>

But the second derivation step doesn't seem to mean anything. This is
analogous to having minInclusive=10 in the base and minExclusive=0 in
derived, which is not allowed by the spec.

It seems to be a good change to allow "length" after "min/maxLength",
not the other way around.

[1] http://www.w3.org/2001/05/xmlschema-errata#e2-35

Sandy Gao
Software Developer, IBM Canada
(1-905) 413-3255
Received on Monday, 10 November 2003 17:17:20 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 23:09:01 UTC