[Bug 2177] R-179: Defect in schema component model wrt enumeration and annotations

http://www.w3.org/Bugs/Public/show_bug.cgi?id=2177

           Summary: R-179: Defect in schema component model wrt enumeration
                    and annotations
           Product: XML Schema
           Version: 1.0
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: XSD Part 2: Datatypes
        AssignedTo: cmsmcq@w3.org
        ReportedBy: sandygao@ca.ibm.com
         QAContact: www-xml-schema-comments@w3.org


Consider the following example: 

<!-- other Address derivations for more countries -->
<simpleType name="USState">
 <restriction base="string">
  <enumeration value="AK">
   <annotation>lt;documentation>Alaska<documentation>lt;annotation>
  <enumeration>
  <enumeration value="AL">
    <annotation>lt;documentation>Alabama<documentation>lt;annotation>
  <enumeration>
  <enumeration value="AR">
    <annotation>lt;documentation>Arkansas<documentation>lt;annotation>
  <enumeration>
  < and so on ... -->
 <restriction>
<simpleType>

Per Part 2, http://www.w3.org/TR/xmlschema-2/#ct-enumeration 

{value} A set of values from the value space of the {base type definition}. 
{annotation} Optional. An annotation. 

and

Mapping XML Rep to schema components, 

{annotation} The annotations corresponding to all the <annotation> element 
information items in the [children], if any. 

and 

Schema Representation Constraint: Multiple enumerations 

If multiple <enumeration> element information items appear as [children] of a 
<simpleType> the {value} of the enumeration component should be the set of all 
such [value]s. 

This results in one enumeration component in the USState simple type 
component's {facets} property. That is, 

enumeration 
{value} = {AK, AL, AR, .. }
{annotation} = This is processor dependent.

This defect applies to enumeration and pattern schema components. This is not a 
critical issue and just a defect, I believe. 

See:
http://lists.w3.org/Archives/Public/www-xml-schema-comments/2002OctDec/0000.html

Received on Wednesday, 14 September 2005 18:40:30 UTC