|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.milyn.container.plugin.PayloadProcessor
public class PayloadProcessor
Processor class for an abstract payload type.
This class can be used to ease Smooks integration with application containers (for example ESBs). It works out how to filter the supplied Object payload through Smooks, to produce the desiredresult type.
The "payload" object supplied to the process(Object, org.milyn.container.ExecutionContext)
method can be one of type:
String,Byte array,Reader,InputStream,Source,SourceResult, orJavaSource).SourceResult payload type allows full control over the filter
Source and Result.
| Constructor Summary | |
|---|---|
PayloadProcessor(Smooks smooks,
ResultType resultType)
Public constructor. |
|
| Method Summary | |
|---|---|
Object |
process(Object payload,
ExecutionContext executionContext)
Process the supplied payload. |
void |
setJavaResultBeanId(String javaResultBeanId)
Set the bean ID to be unpacked from a JavaResult. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public PayloadProcessor(Smooks smooks,
ResultType resultType)
smooks - The Smooks instance to be used.resultType - The required result type.| Method Detail |
|---|
public void setJavaResultBeanId(String javaResultBeanId)
JavaResult.
Only relevant for ResultType.JAVA. If not specified, the
complete result Map
will be returned as the result of the process(Object, org.milyn.container.ExecutionContext)
method call.
javaResultBeanId - The bean ID to be unpacked.
public final Object process(Object payload,
ExecutionContext executionContext)
throws SmooksException
payload - The payload to be filtered. See class level javadoc for supported data types.
ResultType supplied in the
constructor.
SmooksException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||