xsl-list
[Top] [All Lists]

Re: [xsl] instance-of schema-element

2008-03-14 11:54:11
On 14/03/2008, Michael Kay <mike(_at_)saxonica(_dot_)com> wrote:

 > With this approach I need some way of validating the XML from
 > within the XSLT and then be able to handle any validation failures...


Not possible in standard XSLT 2.0, but you could try saxon:try().

Ahh ok, thanks.

I'm already using saxon:parse but I think saxon:try might be step too far...

It looks like I'll have to recreate the validation checks within the
transform - all simple enumerations but a pain nonetheless.

It would be useful to have little more control over validation within
the transform:

- check if something would be valid if validated (like say castable
as... maybe validatable as!)

- handle validation failures, such as validating the input and
reporting problems, or ignoring invalid elements: processing 1000
repeating elements where the lot fail because 1 of them fails
validation is a reasonably common problem.


thanks
-- 
Andrew Welch
http://andrewjwelch.com
Kernow: http://kernowforsaxon.sf.net/

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--