Package org.ametys.runtime.cocoon
Class ThreadSafeTraxProcessor
java.lang.Object
org.apache.avalon.framework.logger.AbstractLogEnabled
org.ametys.runtime.cocoon.ThreadSafeTraxProcessor
- All Implemented Interfaces:
- URIResolver,- Disposable,- Initializable,- Component,- LogEnabled,- Parameterizable,- Serviceable,- XSLTProcessor
public class ThreadSafeTraxProcessor
extends AbstractLogEnabled
implements XSLTProcessor, Serviceable, Initializable, Disposable, Parameterizable, URIResolver
Adaptation of Excalibur's XSLTProcessor implementation to allow for better error reporting. This implementation is also threadsafe.
It also handles a
It also handles a
Templates cache, for performance purpose.- 
Nested Class SummaryNested ClassesModifier and TypeClassDescriptionstatic enumThe validity of the current stylesheet.static classSpecialXSLTProcessor.TransformerHandlerAndValiditywith information about the cache state of the underlyingTemplates.Nested classes/interfaces inherited from interface org.apache.excalibur.xml.xslt.XSLTProcessorXSLTProcessor.TransformerHandlerAndValidity
- 
Field SummaryFields inherited from interface org.apache.excalibur.xml.xslt.XSLTProcessorROLE
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionvoiddispose()DisposablegetTransformerHandler(Source stylesheet) getTransformerHandler(Source stylesheet, XMLFilter filter) getTransformerHandlerAndValidity(Source stylesheet) getTransformerHandlerAndValidity(Source stylesheet, XMLFilter filter) voidInitializevoidparameterize(Parameters params) Configure the componentCalled by the processor when it encounters an xsl:include, xsl:import, or document() function.voidservice(ServiceManager manager) Compose.voidsetTransformerFactory(String classname) voidtransform(Source source, Source stylesheet, Parameters params, Result result) Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabledenableLogging, getLogger, setupLogger, setupLogger, setupLogger
- 
Constructor Details- 
ThreadSafeTraxProcessorpublic ThreadSafeTraxProcessor()
 
- 
- 
Method Details- 
serviceCompose. Try to get the store- Specified by:
- servicein interface- Serviceable
- Throws:
- ServiceException
 
- 
initializeInitialize- Specified by:
- initializein interface- Initializable
- Throws:
- Exception
 
- 
disposeDisposable- Specified by:
- disposein interface- Disposable
 
- 
parameterizeConfigure the component- Specified by:
- parameterizein interface- Parameterizable
- Throws:
- ParameterException
 
- 
setTransformerFactory- Specified by:
- setTransformerFactoryin interface- XSLTProcessor
 
- 
getTransformerHandler- Specified by:
- getTransformerHandlerin interface- XSLTProcessor
- Throws:
- XSLTProcessorException
 
- 
getTransformerHandlerpublic TransformerHandler getTransformerHandler(Source stylesheet, XMLFilter filter) throws XSLTProcessorException - Specified by:
- getTransformerHandlerin interface- XSLTProcessor
- Throws:
- XSLTProcessorException
 
- 
getTransformerHandlerAndValiditypublic XSLTProcessor.TransformerHandlerAndValidity getTransformerHandlerAndValidity(Source stylesheet) throws XSLTProcessorException - Specified by:
- getTransformerHandlerAndValidityin interface- XSLTProcessor
- Throws:
- XSLTProcessorException
 
- 
getTransformerHandlerAndValiditypublic XSLTProcessor.TransformerHandlerAndValidity getTransformerHandlerAndValidity(Source stylesheet, XMLFilter filter) throws XSLTProcessorException - Specified by:
- getTransformerHandlerAndValidityin interface- XSLTProcessor
- Throws:
- XSLTProcessorException
 
- 
transformpublic void transform(Source source, Source stylesheet, Parameters params, Result result) throws XSLTProcessorException - Specified by:
- transformin interface- XSLTProcessor
- Throws:
- XSLTProcessorException
 
- 
resolveCalled by the processor when it encounters an xsl:include, xsl:import, or document() function.- Specified by:
- resolvein interface- URIResolver
- Parameters:
- href- An href attribute, which may be relative or absolute.
- base- The base URI in effect when the href attribute was encountered.
- Returns:
- A Source object, or null if the href cannot be resolved, and the processor should try to resolve the URI itself.
- Throws:
- TransformerException- if an error occurs when trying to resolve the URI.
 
 
-