cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Berin Loritsch <>
Subject Compiling XML, and its replacement (was Re: [RT] the quest for the perfect template language)
Date Thu, 03 Apr 2003 13:09:22 GMT
Bertrand Delacretaz wrote:
> Le Mercredi, 2 avr 2003, à 20:25 Europe/Zurich, Stefano Mazzocchi a écrit :
> <snips cause="commenting on some specifics only"/>
>> ...IMHO, the template language which is closer to the optimum is XSLT 
>> but only with one change:

Imagine using YAML (with a YAML to XML converter), or anything else
you may want.

BTW, My Binary XML project ( has the ability
to compile an XML document into a Java Class (I know this is nothing
extraordinary as XSP has been doing it for years).  However what is
very different from XSP is the following:

1) No Java file is ever written (it uses BCEL)
2) No Class file *needs* to be written (although it is an option)
3) The original document name and the line numbers are part of the
    generated source code.
    * That means the Stack trace has debug information you can

As long as your solution can be translated into an InputSource that
interprets your solution as a SAX stream, the BCEL compiler will still
work with it.

There is still alot to do with the project, and on the TODO list is:
* Enable callbacks
   - I am still struggling with how to recognize them in the source
   - Trying to decide if I want to limit its support as an XInclude
     only approach, or more generic.
* Finish the XMLRepository
   - Uses weak references, so garbage collection is friendly
   - Need to add support for monitoring the source file as an option;
     that way the XMLRepository can update the class file behind the
* Make the compiler extendable so that things like XSP can be included

There are a few good points about Binary XML as it stands right now:
Every XML document is defined as an org.xml.sax.XMLReader so it will
incorporate itself seamlessly with any XML enabled application (Cocoon
included).  It is not dependant on any outside library with the one
obvious exception of BCEL.

View raw message