xmlvalidate warn attribute
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Graham_Wagener
Posted On:   Sunday, January 13, 2008 05:49 PM

The xmlvalidate task has a warn attribute for which the description in the Ant manual says "log parser warn events." Where does it log the events to? I've tried setting it to true and false and I get the same output for a test malformed xml file. The reason I'm trying to use the warn attribute is that I want to add some handling for files that fail to validate so I need a way to get the results of the xmlvalidate task from within ant. Failonerror has to be false otherwise the build halts. I've tried surrounding it with a trycatch task from ant-contrib, but that won't catch failonerror and xmlvalidate doesn't throw any exceptions. Is there any other way I can get the results? Cheers, Graham    More>>

The xmlvalidate task has a warn attribute for which the description in the Ant manual says "log parser warn events." Where does it log the events to? I've tried setting it to true and false and I get the same output for a test malformed xml file.


The reason I'm trying to use the warn attribute is that I want to add some handling for files that fail to validate so I need a way to get the results of the xmlvalidate task from within ant. Failonerror has to be false otherwise the build halts. I've tried surrounding it with a trycatch task from ant-contrib, but that won't catch failonerror and xmlvalidate doesn't throw any exceptions. Is there any other way I can get the results?


Cheers,

Graham

   <<Less

Re: xmlvalidate warn attribute

Posted By:   Graham_Wagener  
Posted On:   Sunday, January 13, 2008 06:01 PM

Sorry, it appears I was wrong, trycatch does catch failonerror. Regardless, I'd still like to know about the warn log.
About | Sitemap | Contact