From: David C. <dc...@st...> - 2007-04-27 21:05:38
|
Stefan Bodewig wrote: > On Wed, 25 Apr 2007, David Carver <dc...@st...> wrote: > >>>> This article shows how to pre-compile a schema using JAXP 1.3 api: >>>> >>>> https://jaxp.dev.java.net/article/jaxp-1_3-article.html#Compile_Schema(s) >>>> >>>> >>> I will look into it, thanks for the link. >>> >>> This probably should go into XMLUnit 1.2, I'd like to see us >>> finalize 1.1 pretty soon. There is nothing bad in having frequent >>> releases, more frequent than every four years, that is 8-) >>> >>> >> Yeah, I agree. If I can get some spare time, I'll take an initial >> stab at getting it going. >> > > That would be nice. > I've got some basic code working for this. Currently just takes the first XML Schema parser available and tries to compile the schema. If any Exceptions are tossed during the compilation, it will fail the assertion. Seems to work. I may need to refactor some of the names it uses, but it worked on a couple of schemas that I tested it against. I'll run it in our tests for a while before contributing it back. It's a fairly small change but can wait until 1.2 Dave |