DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12557>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12557

Validation makes a document invalid by specify invalid form for an optional and fixed 
attribute

           Summary: Validation makes a document invalid by specify invalid
                    form for an optional and fixed attribute
           Product: Xerces2-J
           Version: 2.1.0
          Platform: PC
        OS/Version: Windows NT/2K
            Status: NEW
          Severity: Critical
          Priority: Other
         Component: Other
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


The xlinks.xsd schema of GML has an attribute group as follows (the default 
attribute form is unqualified - note the explicit attribute form on the first 
attribute in the group):

<xsd:attributeGroup name="simpleLink">
                <xsd:attribute name="type" type="xsd:string" use="optional" 
fixed="simple" form="qualified"/>
                <xsd:attribute ref="xlink:href" use="optional"/>
                <xsd:attribute ref="xlink:role" use="optional"/>
                <xsd:attribute ref="xlink:arcrole" use="optional"/>
                <xsd:attribute ref="xlink:title" use="optional"/>
                <xsd:attribute ref="xlink:show" use="optional"/>
                <xsd:attribute ref="xlink:actuate" use="optional"/>
        </xsd:attributeGroup>

This attribute group is then referenced from complex type definitions. When an 
instance document without these attributes is validated, Xerces adds the type 
attribute because it is fixed to the value "simple". This is the desired 
behaviour. However, Xerces fails to qualify the attribute by specifying its 
namespace and prefix. Hence, the added type attribute breaks the validity of 
the instance document. This looks like a critical bug to me because a valid 
instance document is made invalid when Xerces validates it. If required, I can 
supply the exact schemas and instance documents.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to