Subject: Re: [xsl] Simple XSL Pipelines From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx> Date: Tue, 09 Mar 2010 18:14:18 -0500 |
On Tue, 2010-03-09 at 23:03 +0200, Jacobus Reyneke wrote:
> The idea is something like: > data.xml -> filter.xls -> layout.xls -> targetmedia.xsl -> > data_for_mobile_phone.svg
XProc, the XML Pipelining Language, is probably what you want. It's not yet a W3C Recommendation, but is likely to be one soon, and in any case the language should be very stable at this point. See e.g. http://xmlcalabash.com/ for an implementation.
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:saxon="http://saxon.sf.net/" version="2.0" extension-element-prefixes="saxon">
<xsl:variable name="processes"> <step>filter.xsl</step> <step>layout.xsl</step> <step>targetmedia.xsl</step> </xsl:variable>
<xsl:template match="/"> <xsl:for-each select="$processes/step"> <xsl:message> <xsl:text>
... Applying </xsl:text> <xsl:value-of select="."/> </xsl:message> <saxon:assign name="document" select="saxon:transform( saxon:compile-stylesheet(doc(.)), $document)"/> <!-- A third argument to saxon:transform can specify runtime parameters for any (or all) steps; see the documentation --> </xsl:for-each> <xsl:sequence select="$document"/> <xsl:message>
... Done</xsl:message> </xsl:template>
Cheers, Wendell
====================================================================== Wendell Piez mailto:wapiez@xxxxxxxxxxxxxxxx Mulberry Technologies, Inc. http://www.mulberrytech.com 17 West Jefferson Street Direct Phone: 301/315-9635 Suite 207 Phone: 301/315-9631 Rockville, MD 20850 Fax: 301/315-8285 ---------------------------------------------------------------------- Mulberry Technologies: A Consultancy Specializing in SGML and XML ======================================================================
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Simple XSL Pipelines, Liam R E Quin | Thread | Re: [xsl] Simple XSL Pipelines, Jacobus Reyneke |
RE: [xsl] Simple XSL Pipelines, Michael Kay | Date | [xsl] Problems with page-position=", Mark Anderson |
Month |