[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

Re: [xsl] Proposed requirements for XSLT 3.0 try/catch and validation


Subject: Re: [xsl] Proposed requirements for XSLT 3.0 try/catch and validation
From: Andrew Welch <andrew.j.welch@xxxxxxxxx>
Date: Wed, 24 Jul 2013 10:58:21 +0100

> If the context element is assessed invalid (without consideration of its
children), then validation fails and control falls into the xsl:catch. For
example, below I misspelled Book (note the 3 o's) so validation fails and
control falls into the xsl:catch where the XSLT program attempts to repair
<Boook>:
>

I'm not sure using validation like this is the right approach... if
you get a No from the Yes/No result of validation, you then have to
pass it through your 'repair' code to fix it up, then re-validate...
then what if it fails again?

Ultimately if you have the code to repair the value, then its that
same code that will also be used to ensure correctness of the value in
the first place - no need for XSD involvement at that stage.



--
Andrew Welch
http://andrewjwelch.com


Current Thread
Keywords