Michael's previous reply closed off this avenue of solution since XERCES doesn't support (them) robustly or at all! (My e-mail specifically named the properties of interest).

Phil :n(

On Mon, 2004-01-12 at 15:35, Holliday, Donald B. (LNG-CSP) wrote:
The properties you refer to (http://xml.apache.org/xerces-j/properties.html) are for setting and getting the properties for the parser.  Which properties did you have in mind, and how would you use them to solve this problem?
 
Thanks,

Donald Holliday


-----Original Message-----
From: Phil Weighill-Smith [mailto:[EMAIL PROTECTED]
Sent: Saturday, January 10, 2004 3:38 AM
To: [EMAIL PROTECTED]
Subject: Re: XS Validation handling


I think the XERCES SAX and DOM parsers (you could perhaps use the latter for your DOM validation from your other query?) have some properties that could be of use:

http://xml.org/sax/properties/dom-node (SAX parser) and
http://apache.org/xml/properties/dom/current-element-node (DOM parser).

See
http://xml.apache.org/xerces-j/properties.html. Once you've got the node you should be able to determine an XPath for it. You may also need to determine if the error relates to an attribute of that node by interpreting the actual error you get from the parser...

Phil :n)

On Sat, 2004-01-10 at 00:50, Jan Pernica wrote:
Hi everybody

I have XML and XS schema. Let's assume that the validated XML is valid XML
(well formed). But there are XS validation errors like theese
[Error] test.xml:10:25: cvc-pattern-valid: Value '6910018dd093' is not
facet-valid with respect to pattern '[0-9]{9,10}' for type 'RCType'.
[Error] test.xml:10:25: cvc-type.3.1.3: The value '6910018dd093' of element
'rc' is not valid.
[Error] test2.xml:80:44: cvc-attribute.3: The value '9'0'1.01.2003' of
attribute 'datVzniku' on element 'poistenie' is not valid with respect to
its type, 'DatumType'.

The question is: how do I get Xpath to element or attribute with an error?

Thanks for any hints

Regards

Jan Pernica
mailto:[EMAIL PROTECTED]
http://www.pernica.org


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
--
Phil Weighill-Smith <[EMAIL PROTECTED]>
Volantis Systems
--
Phil Weighill-Smith <[EMAIL PROTECTED]>
Volantis Systems

Reply via email to