Hi All,

I have modified my Xalan.exe source to provide more control over the XML
validation features by adding more command line options.
The new options include:
-n filename    To use filename as external no-namespace schema for
validating source XMLs.
-s filename    To use filename as external schema for vaildating source
XMLs.
-f             To treat validation errors as fatal.

Now I have a few questions.
1. Should I send a patch to this list with the changes? Is someone
willing to review it and comment on it / include it if it's good enough?
2. The -f switch I could only get to work correctly if I removed the
catch(...) block in xalanc/Xslt/FunctionDocument.cpp:parseDoc().
(Otherwise invalid XMLs included with the document function were simply
skipped and I needed the parser to completely stop with an error
condition.) However I'm not sure if this is the correct way to do it.
Any other suggestions?

I also have an other question regarding the XML Schema I use to validate
my XMLs.
I have an 'id' attribute which has a wider codomain than the XML ID's
QName type allows. So I derived a new type from xs:string by restriction
and created a unique constraint like this in my document element:

<xs:unique name="IDUniqueConstraint">
  <xs:selector xpath="element1 | element1/element2 |
element1/element2/element3 | elem"/>
  <xs:field xpath="@id"/>
</xs:unique>

As far as I can tell this should be a valid uniqueness constraint but
any parser I came across happily validated my XMLs which contained to
ids with the same value. Did I misunderstand something in the XSD
specification or is this simply such a rare case that it's skipped
attention so far?

Thanks in advance:

        Andras Babos.


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

Reply via email to