[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Even if you're not ... was If you're going to the W3C meet
* Michael Kay <mike@s...> [2005-01-29 11:17]: > > This is a general problem I'm having, how do you create hooks, > > callbacks, er, how do you create an XSLT framework? > One answer is to run XSLT tasks under the control of a pipeline > processor such as Orbeon. > OK, it's yet another tool to master, and we all have our limits > somewhere... That's nice. I'm writing a pipeline processor that makes heavy use of Saxon. A pipeline processor doesn't seem quite right, because, taking the project definition to Ant example, it seems like a hook could be defined as an extra mode to run through. <project name="${project-definition/name}" default="default"> for each mode in (javac, javac, javacc, antlr, jython, jar, dist) <xsl:apply-templates select="project-definition" mode="$mode"/> </project> That's pseudo code. Maybe a good method is to have the user select their modes by definining a style sheet? <xsl:stylesheet> <xsl:import href="xslt/taskdef/javac.xslt"/> <xsl:import href="xslt/taskdef/junit.xslt"/> <xsl:import href="xslt/taskdef/javacc.xslt"/> <xsl:import href="xslt/taskdef/antlr.xslt"/> <xsl:import href="xslt/taskdef/jython.xslt"/> <xsl:template match="project-definition"> <xsl:apply-templates select="." mode="taskdef.javac"/> <xsl:apply-templates select="." mode="taskdef.junit"/> <xsl:apply-templates select="." mode="taskdef.jython"/> <xsl:apply-templates select="." mode="taskdef.antlr"/> <xsl:apply-templates select="." mode="taskdef.jython"/> </xsl:template> </xsl:stylesheet> Framework might have been too strong a word. I guess, if I have Ant, I have a pipeline, though not as fancy as Oberon. And I suppose I could add a task definition section to the project file, and use that to generate the above template file. -- Alan Gutierrez - alan@e...
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|