org.jboss.soa.esb.listeners.gateway
Class LocalFileNameMessageComposer<T extends java.io.File>
java.lang.Object
org.jboss.soa.esb.listeners.gateway.LocalFileMessageComposer<T>
org.jboss.soa.esb.listeners.gateway.LocalFileNameMessageComposer<T>
- All Implemented Interfaces:
- MessageComposer<T>
public class LocalFileNameMessageComposer<T extends java.io.File>
- extends LocalFileMessageComposer<T>
Composer that simply set the file name as the message contents.
This can be used when handling large files and one wants to avoid parsing the file contents.
Usage (for example inside a fs-listener element ):
<property name="composer-class" value="org.jboss.soa.esb.listeners.gateway.LocalFileNameMessageComposer"/>
- Since:
- 4.3
- Author:
- Daniel Bevenius
Method Summary |
protected java.lang.Object |
getPayload(T inputFile)
Simply returns the absolute path of the passed in file. |
void |
setConfiguration(ConfigTree config)
Set the composer's configuration. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LocalFileNameMessageComposer
public LocalFileNameMessageComposer()
getPayload
protected java.lang.Object getPayload(T inputFile)
- Simply returns the absolute path of the passed in file.
- Overrides:
getPayload
in class LocalFileMessageComposer<T extends java.io.File>
- Parameters:
inputFile
- - input File object
- Returns:
- Object - String that contains the absulute path to the file.
setConfiguration
public void setConfiguration(ConfigTree config)
throws ConfigurationException
- Description copied from interface:
MessageComposer
- Set the composer's configuration.
- Specified by:
setConfiguration
in interface MessageComposer<T extends java.io.File>
- Overrides:
setConfiguration
in class LocalFileMessageComposer<T extends java.io.File>
- Parameters:
config
- Composer configuration.
- Throws:
ConfigurationException
- Bad configuration.