The root element for a transform.
If the href attribute is specified its content is treated as the URI of an XSL transformation, and either the pipeline:content element can specify inline data, or a urid:fetch operation can be used.
Otherwise pipeline:transform must either contain a pipeline:transformation element or a pipeline:transformations element followed by markup defining the data to be processed.
Care must be taken when changing compilable attribute from its default value as XSLT compilers are not yet capable of handling all XSLT constructs.
Attribute | Description | Type | Default | Options | Use |
---|---|---|---|---|---|
cache | Controls whether templates will be cached. If this attribute is false then templates are never cached. Otherwise they are cached using a composite key constructed from the fully resolved URL and the compilable attribute value. The size of the cache cannot be configured and is unlimited in size, meaning that templates are never removed | xs:boolean | false | optional | |
compilable | Together with the setting of the compile attribute on the transform element in the pipeline-configuration section of mcs-config.xml file, this attribute specifies whether the XSL transform should be compiled or not. If both values are 'true', the transform is compiled. | xs:boolean | false | optional | |
href | The URI of an XSL transformation. | xs:anyURI | none | optional |
<?xml version="1.0" encoding="UTF-8"?>
<html xmlns="http://www.w3.org/2002/06/xhtml2"
xmlns:pipeline="http://www.volantis.com/xmlns/marlin-pipeline"
xmlns:webd="http://www.volantis.com/xmlns/marlin-web-driver">
<head>
<title>DCI elements</title>
</head>
<body>
<div>
<pipeline:transform href="test.xsl">
<webd:get url="http://weather.yahooapis.com/forecastrss">
<webd:parameters>
<webd:parameter name="p" value="USWA0395"/>
<webd:parameter name="u" value="c"/>
</webd:parameters>
</webd:get>
</pipeline:transform>
</div>
</body>
</html>
The test.xsl transform must have the following form:
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
xmlns:yweather="http://xml.weather.yahoo.com/ns/rss/1.0"
xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#">
<xsl:output method="xml"/>
<xsl:template match="/">
<div xmlns="http://www.w3.org/2002/06/xhtml2">
<h3>
<xsl:value-of select="/rss/channel/item/title"/>
</h3>
<p>Current Conditions: <xsl:value-of select="/rss/channel/item/yweather:condition/@text"/>,
<xsl:value-of select="/rss/channel/item/yweather:condition/@temp"/>
<xsl:value-of select="/rss/channel/yweather:units/@temperature"/>.</p>
</div>
</xsl:template>
</xsl:stylesheet>