xmlc-2.2 is now used by Barracuda! + other changes...

Jacob Kjome <[email protected]>
Newsgroups gmane.comp.java.enhydra.barracuda.general
Message-ID <[email protected]>
I just wanted to let everyone know that the latest CVS of Barracuda now 
uses xmlc-2.2 (latest CVS, post-alpha4) instead of xmlc-2.1.  I also 
modified the way that DefaultDOMWriter works.  Actually, I'd like some 
feedback on the latter because there were some changes to the 
interface.  I'm thinking that not many people will be affected by the 
change, but you never know.  If people could try it out with their apps and 
tell me if there are any real hardships in getting things to work correctly 
with the new source, that would be helpful.  Again, I don't foresee too 
many issues.

Below are the comments I made when committing these changes.  They should 
explain most of what I did.  Please send comments and questions if you have 
them....


1.  Verified that xmlc-2.2 (current cvs) is not only compatible with Barracuda,
it solves all the gotchas that we had before.  You can now have a stock install
of Ant with Xerces2 and xml-apis.jar in ANT_HOME/lib and successfully build
Barracuda at the same time.  You can have Xerces2 and xmlParserAPIs.jar in
CATALNIA_HOME/common/endorsed and xmlc's xerces in CATALNIA_HOME/shared/lib or
WEB-INF/lib and xmlc classes based upon xml files will work (remember under
xmlc-2.1, these bombed out because there was a clash between xerces1 and
xerces2).  So, basically, we don't have to expound on any caveats to using xmlc
anymore.  Things just work with default installs!!!!  Note that I still am not
copying xerces to WEB-INF/lib because even though xerces is wrapped
(org.enhydra.apache.xerces), it still
contains org.w3c.dom, javax.xml, and org.xml packages.  David Li is working on
getting rid of those and once that happens we can put it back in WEB-INF/lib.

1b.  Note I have removed the Xmlc taskdef from Barracuda's source
now that it exists over at the XMLC project CVS.  Also note that it has already
been enhanced by David Li to notice not only changes to *ML files but also
corresponding *.xmlc files.  And I applied a patch from Stefan Armbruster which
allows the task to recursively look in parent directories for options.xmlc so
that one can have nested subdirectories containing *ML templates all using a
single options.xmlc file.  The xmlc-taskdef.jar is now incldued in 
WEB-INF/jars.
I also applied another patch from Stefan to fix some logging
issues in the Localize task.  I also fixed the EventBuilder task to use 
whatever
XMLReader is available rather than failing if it can't find the Xerces parser.
This should probably be used elsewhere where SAX2 parsers are utilized.

2.  Modified DefaultDOMWriter and in the process, removed printPretty,
preventCaching, and maxAge from DefaultViewHandler and ComponentGateway.
Dealing with these values is now entirely localized to 
DefaultDOMWriter.  If you
want to override defaults, then override getDOMWriter() or just create a
DefaultDOMWriter and set the properties. before calling the write() method.

3.  Updated Diez' page model to conform to the new stuff and am now 
successfully
overriding getDOMWriter() and being able to set OutputOptions so that the
doctype will be written for his example pages.  cool!

4.  Updated build.xml and version.properties to account for the new xmlc
jars.

5.  Removed the core.util.dom.io package.  All classes (very few) referencing
that package now reference org.enhydra.xml.io.*.  I believe that all needed
custom modifications have already been moved into XMLC's source.  They must 
have
because everything seems to work perfectly.

Jake
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.