java.lang.Objectorg.apache.avalon.framework.logger.AbstractLogEnabled
org.apache.cocoon.xml.AbstractXMLProducer
org.apache.cocoon.xml.AbstractXMLPipe
org.apache.cocoon.transformation.AbstractTransformer
org.apache.cocoon.transformation.TraxTransformer
All Implemented Interfaces:
org.apache.avalon.framework.activity.Disposable, CacheableProcessingComponent, org.apache.avalon.framework.service.Serviceable, org.apache.avalon.framework.configuration.Configurable, Transformer, XMLPipe, org.apache.avalon.excalibur.pool.Recyclable, XMLProducer
Direct Known Subclasses:
DeliTransformer
The - stylesheet processorxslt - sitemap.transformer.xslt - Uses - the last modification date of the xslt document for validation32 -
This Transformer is used to transform the incoming SAX stream using a TrAXProcessor. Use the following sitemap declarations to define, configure and parameterize it:
In the map:sitemap/map:components/map:transformers:<map:transformer name="xslt" src="org.apache.cocoon.transformation.TraxTransformer">The <use-request-parameter> configuration forces the transformer to make all request parameters available in the XSLT stylesheet. Note that this has implications for caching of the generated output of this transformer.
<use-request-parameters>false</use-request-parameters> <use-browser-capabilities-db>false</use-browser-capabilities-db> <use-session-info>false</use-session-info> <xslt-processor-role>xslt</xslt-processor-role> <transformer-factory>org.apache.xalan.processor.TransformerFactoryImpl</transformer-factory> <check-includes>true</check-includes> </map:transformer>
The <use-cookies> configuration forces the transformer to make all
cookies from the request available in the XSLT stylesheets.
Note that this has implications for caching of the generated output of this
transformer.
This property is false by default.
The <use-session-info> configuration forces the transformer to make all
of the session information available in the XSLT stylesheetas.
These infos are (boolean values are "true" or "false" strings: session-is-new,
session-id-from-cookie, session-id-from-url, session-valid, session-id.
This property is false by default.
Note that this has implications for caching of the generated output of
this transformer.
The <xslt-processor-role> configuration allows to specify the TrAX processor (defined in
the cocoon.xconf) that will be used to obtain the XSLT processor. This allows to have
several XSLT processors in the configuration (e.g. Xalan, XSLTC, Saxon, ...) and choose
one or the other depending on the needs of stylesheet specificities.
If no processor is specified, this transformer will use the XSLT implementation
that Cocoon uses internally.
The <transformer-factory> configuration allows to specify the TrAX transformer factory
implementation that will be used to obtain the XSLT processor. This is only useful for
compatibility reasons. Please configure the XSLT processor in the cocoon.xconf properly
and use the xslt-processor-role configuration mentioned above.
The <check-includes> configuration specifies if the included stylesheets are
also checked for changes during caching. If this is set to true (default), the
included stylesheets are also checked for changes; if this is set to false, only
the main stylesheet is checked. Setting this to false improves the performance,
and should be used whenever no includes are in the stylesheet. However, if
you have includes, you have to be careful when changing included stylesheets
as the changes might not take effect immediately. You should touch the main
stylesheet as well.
In a map:sitemap/map:pipelines/map:pipeline:
<map:transform type="xslt" src="stylesheets/yours.xsl">All <parameter> declarations will be made available in the XSLT stylesheet as xsl:variables.
<parameter name="myparam" value="myvalue"/> </map:transform>
< - a href="mailto:pier@apache.org">Pierpaolo Fumagalli< - a href="mailto:dims@yahoo.com">Davanum Srinivas< - a href="mailto:cziegeler@apache.org">Carsten Ziegeler< - a href="mailto:giacomo@apache.org">Giacomo Pati< - a href="mailto:ovidiu@cup.hp.com">Ovidiu Predescu< - a href="mailto:marbut@hplb.hpl.hp.com">Mark H. Butler< - a href="mailto:stefano@apache.org">Stefano MazzocchiSVN - $Id: TraxTransformer.java 433543 2006-08-22 06:22:54Z crossley $| Field Summary | ||
|---|---|---|
| protected ServiceManager | manager | The service manager instance (protected because used by subclasses) |
| protected Map | objectModel | The object model (protected because used by subclasses) |
| protected Map | logicSheetParameters | Logicsheet parameters (protected because used by subclasses) |
| protected TransformerHandler | transformerHandler | The trax TransformerHandler |
| protected SourceValidity | transformerValidity | The validity of the Transformer |
| Fields inherited from org.apache.cocoon.xml.AbstractXMLProducer: |
|---|
| EMPTY_CONTENT_HANDLER, xmlConsumer, contentHandler, lexicalHandler |
| Method from org.apache.cocoon.transformation.TraxTransformer Summary: |
|---|
| configure, dispose, endDocument, getKey, getLogicSheetParameters, getValidity, isValidXSLTParameterName, recycle, service, setConsumer, setup, startDocument |
| Methods from org.apache.cocoon.xml.AbstractXMLPipe: |
|---|
| characters, comment, endCDATA, endDTD, endDocument, endElement, endEntity, endPrefixMapping, ignorableWhitespace, processingInstruction, setDocumentLocator, skippedEntity, startCDATA, startDTD, startDocument, startElement, startEntity, startPrefixMapping |
| Methods from org.apache.cocoon.xml.AbstractXMLProducer: |
|---|
| recycle, setConsumer, setContentHandler, setLexicalHandler |
| Methods from java.lang.Object: |
|---|
| equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method from org.apache.cocoon.transformation.TraxTransformer Detail: |
|---|
|
|
|
|
|
|
|
|
ServiceManager instance used by this
Serviceable. |
XMLConsumer that will receive XML data. |
SourceResolver, the Map with
the object model, the source and sitemap
Parameters used to process the request. |
|