[
https://issues.apache.org/jira/browse/XMLBEANS-250?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jacob Danner resolved XMLBEANS-250.
-----------------------------------
Resolution: Cannot Reproduce
Unable to reproduce this using information given from bug. If this is still an
issue for you from this scenario, please include a test case and/or include
information from error listener in xmloptions.setErrorListener to see detailed
information about the issue.
> Validation fails on an xml whose root node is unknown
> -----------------------------------------------------
>
> Key: XMLBEANS-250
> URL: https://issues.apache.org/jira/browse/XMLBEANS-250
> Project: XMLBeans
> Issue Type: Bug
> Components: Validator
> Affects Versions: Version 2
> Reporter: rafiq ahmad
> Fix For: Version 2
>
>
> I am trying to validate an xml file whose root node is unknown. So I am using
> the following code to parse and validate but validation fails.
> XMLObject xmlObject = XmlObject.Factory.parse(new FileReader(file));
> boolean isValid = xmlObject.validate(); //isValid becomes false eventhough
> file is valid
> When I looked at closely, I notice xmlObject is not pointing to the root
> document object (In my case ReturnDataDocument since ReturnData is the root
> node of xml) but pointing to XmlAnyTypeImpl.
> When I use the specific object , it works.
> ReturnDataDocument xmlObject = ReturnDataDocument .Factory.parse(new
> FileReader(file));
> boolean isValid = xmlObject.validate(); //isValid is true
--
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: [email protected]
For additional commands, e-mail: [email protected]