[oXygen-user] How does Oxygen Validate XSDs?

Eliot Kimber
Tue Mar 29 12:17:17 CDT 2011


It appears to be user error in that the schema that's giving the errors has
been munged by other code from the schema Oxygen was validating against. I
verified that plain Xerces and Oxygen give the same correct validation
errors when using the unmunged schema.

Cheers,

E.

On 3/29/11 9:35 AM, "Eliot Kimber" <> wrote:

> Radu,
> 
> Thanks for the details. In my code I'm setting up the XSD-specific features
> on the parser (schema source locations, validate = true), getting a doc
> builder from the JAXP factory and parsing the instance, rather than
> validating the schema itself directly. I should be constructing a Xerces
> 2.9.1 parser but I'll have to verify that.
> 
> I'm getting errors about incorrect substitutions and stuff--I'll have to do
> some work to recreate the original failures (I routed around the problem by
> changing the schema).
> 
> I'll try setting up a schema parser as you demonstrate and see if I get the
> same validation result Oxygen gets.
> 
> Cheers,
> 
> E.
> 
> On 3/29/11 9:07 AM, "Radu Coravu" <> wrote:
> 
>> Hi Eliot,
>> 
>> Oxygen uses Xerces by default for validating XSD.
>> Our used Xerces version is 2.9.1 and we have a lot of patches (as you
>> probably already know).
>> 
>> Our validation code is something like:
>> 
>>          XMLGrammarPreparser preparser = ......................
>>          // parse the grammar...
>>          preparser.setErrorHandler(..............);
>>          preparser.preparseGrammar(
>>              XMLGrammarDescription.XML_SCHEMA,
>>              new XMLInputSource(null, systemID, null, reader, null));
>> 
>> 
>> We also have some parser options in the Oxygen Preferences->"XML / XML
>> Parser" which are used to create the parser.
>> 
>> So it's hard to say why this difference occurs, maybe one of our many
>> Xerces patches is a fix for your particular situation...
>> 
>> What error does your validation report?
>> 
>> Regards,
>> Radu
>> 
>> Radu Coravu
>> <oXygen/>  XML Editor, Schema Editor and XSLT Editor/Debugger
>> http://www.oxygenxml.com
>> 
>> 
>> On 3/29/2011 4:40 PM, Eliot Kimber wrote:
>>> I have an XSD that Oxygen validates fine but my own Xerces-based validator
>>> chokes on. Since the client asserts that the schema is valid, I want to
>>> understand why I'm seeing a difference in validation results when I would
>>> have expected them to be the same.
>>> 
>>> Is my understanding correct that Oxygen uses Saxon EE to do schema
>>> validation rather than Xerces?
>>> 
>>> Cheers,
>>> 
>>> E.
>>> 
>> 
>> _______________________________________________
>> oXygen-user mailing list
>> 
>> http://www.oxygenxml.com/mailman/listinfo/oxygen-user
> 
> --
> Eliot Kimber
> Senior Solutions Architect
> "Bringing Strategy, Content, and Technology Together"
> Main: 512.554.9368
> www.reallysi.com
> www.rsuitecms.com
> 
> _______________________________________________
> oXygen-user mailing list
> 
> http://www.oxygenxml.com/mailman/listinfo/oxygen-user

-- 
Eliot Kimber
Senior Solutions Architect
"Bringing Strategy, Content, and Technology Together"
Main: 512.554.9368
www.reallysi.com
www.rsuitecms.com




More information about the oXygen-user mailing list