xerces-j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Khaled Noaman (JIRA)" <xerces-j-...@xml.apache.org>
Subject [jira] Resolved: (XERCESJ-1352) XML Schema 1.1 defaultAttributes
Date Wed, 19 May 2010 16:57:53 GMT

     [ https://issues.apache.org/jira/browse/XERCESJ-1352?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Khaled Noaman resolved XERCESJ-1352.
------------------------------------

    Fix Version/s: 2.10.0
       Resolution: Fixed

Sample xml document works with current code.

> XML Schema 1.1 defaultAttributes 
> ---------------------------------
>
>                 Key: XERCESJ-1352
>                 URL: https://issues.apache.org/jira/browse/XERCESJ-1352
>             Project: Xerces2-J
>          Issue Type: Bug
>          Components: XML Schema 1.1 Structures
>    Affects Versions: 2.9.1
>            Reporter: John Chan
>            Assignee: Khaled Noaman
>            Priority: Minor
>             Fix For: 2.10.0
>
>         Attachments: v01.xml, v01.xsd
>
>
> The defaultAttributes feature does not work properly.   
> 1. The defaultAttributes schema component is never set in the XSDocumentInfo.  
> In the XSDocumentInfo constructor, fDefaultAttributes is set to be the the value of the
defaultsAttributesApply attribute, which is wrong and would be always null.  Instead, it should
be set to the value of the defaultAttributes attribute.
> 2. The defaultAttributeGroup is never set.
> In XSDHandler.traverseShemas(), the condition statement to check whether or not to set
currSchemaDoc.fDefaultGroup is incorrect.  It checks whether the fDefaultAGroup != null, if
so, set it.  But the fDefaultAGroup was never set before.
> 3. The namespace support is not set before validating the schema element's attributes.
 Thus if the defaultAttributes attribute exist on the schema element, the validation of defaultAttributes
will fail.  One way around this is to in the AttributeChecker.checkAttributes() method, do
not try to validate defaultAttributes attribute.  After the namespacesuport is set, then try
to validate the defaultAttributes attribute and set it.  But this is not a particularly elegant
solution.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: j-dev-unsubscribe@xerces.apache.org
For additional commands, e-mail: j-dev-help@xerces.apache.org


Mime
View raw message