|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.camel.builder.xml.XsltBuilder
public class XsltBuilder
Creates a Processor which performs an XSLT transformation of the IN message body
Constructor Summary | |
---|---|
XsltBuilder()
|
|
XsltBuilder(Transformer transformer)
|
Method Summary | |
---|---|
protected void |
addParameters(Transformer transformer,
Map<String,Object> map)
|
protected void |
configureTransformer(Transformer transformer,
Exchange exchange)
Configures the transformerwith exchange specific parameters |
XmlConverter |
getConverter()
|
Map<String,Object> |
getParameters()
|
ResultHandlerFactory |
getResultHandlerFactory()
|
protected Source |
getSource(Exchange exchange)
Converts the inbound body to a Source |
Transformer |
getTransformer()
|
boolean |
isFailOnNullBody()
|
XsltBuilder |
outputBytes()
Sets the output as being a byte[] |
XsltBuilder |
outputDOM()
Sets the output as being a DOM |
XsltBuilder |
outputString()
Sets the output as being a String |
XsltBuilder |
parameter(String name,
Object value)
|
void |
process(Exchange exchange)
Processes the message exchange |
void |
setConverter(XmlConverter converter)
|
void |
setFailOnNullBody(boolean failOnNullBody)
|
void |
setParameters(Map<String,Object> parameters)
|
void |
setResultHandlerFactory(ResultHandlerFactory resultHandlerFactory)
|
void |
setTransformer(Transformer transformer)
|
void |
setTransformerFile(File xslt)
Sets the XSLT transformer from a File |
void |
setTransformerInputStream(InputStream in)
Sets the XSLT transformer from the given input stream |
void |
setTransformerSource(Source source)
Sets the XSLT transformer from a Source |
void |
setTransformerURL(URL url)
Sets the XSLT transformer from a URL |
String |
toString()
|
static XsltBuilder |
xslt(File xslt)
Creates an XSLT processor using the given XSLT source |
static XsltBuilder |
xslt(InputStream xslt)
Creates an XSLT processor using the given XSLT source |
static XsltBuilder |
xslt(Source xslt)
Creates an XSLT processor using the given XSLT source |
static XsltBuilder |
xslt(Transformer transformer)
Creates an XSLT processor using the given transformer instance |
static XsltBuilder |
xslt(URL xslt)
Creates an XSLT processor using the given XSLT source |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public XsltBuilder()
public XsltBuilder(Transformer transformer)
Method Detail |
---|
public String toString()
toString
in class Object
public void process(Exchange exchange) throws Exception
Processor
process
in interface Processor
Exception
- if an internal processing error has occurred.public static XsltBuilder xslt(Transformer transformer)
public static XsltBuilder xslt(Source xslt) throws TransformerConfigurationException
TransformerConfigurationException
public static XsltBuilder xslt(File xslt) throws TransformerConfigurationException
TransformerConfigurationException
public static XsltBuilder xslt(URL xslt) throws TransformerConfigurationException, IOException
TransformerConfigurationException
IOException
public static XsltBuilder xslt(InputStream xslt) throws TransformerConfigurationException, IOException
TransformerConfigurationException
IOException
public XsltBuilder outputBytes()
public XsltBuilder outputString()
public XsltBuilder outputDOM()
public XsltBuilder parameter(String name, Object value)
public Map<String,Object> getParameters()
public void setParameters(Map<String,Object> parameters)
public Transformer getTransformer()
public void setTransformer(Transformer transformer)
public boolean isFailOnNullBody()
public void setFailOnNullBody(boolean failOnNullBody)
public ResultHandlerFactory getResultHandlerFactory()
public void setResultHandlerFactory(ResultHandlerFactory resultHandlerFactory)
public void setTransformerSource(Source source) throws TransformerConfigurationException
source
- the source
TransformerConfigurationException
- is thrown if creating a XSLT transformer failed.public void setTransformerFile(File xslt) throws TransformerConfigurationException
TransformerConfigurationException
public void setTransformerURL(URL url) throws TransformerConfigurationException, IOException
TransformerConfigurationException
IOException
public void setTransformerInputStream(InputStream in) throws TransformerConfigurationException, IOException
TransformerConfigurationException
IOException
public XmlConverter getConverter()
public void setConverter(XmlConverter converter)
protected Source getSource(Exchange exchange)
Source
protected void configureTransformer(Transformer transformer, Exchange exchange)
protected void addParameters(Transformer transformer, Map<String,Object> map)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |