org.apache.servicemix.vfs
Class VFSSendingEndpoint
java.lang.Object
org.apache.servicemix.common.endpoints.AbstractEndpoint
org.apache.servicemix.common.endpoints.SimpleEndpoint
org.apache.servicemix.common.endpoints.ProviderEndpoint
org.apache.servicemix.vfs.VFSSendingEndpoint
- All Implemented Interfaces:
- Endpoint, VFSEndpointType
public class VFSSendingEndpoint
- extends ProviderEndpoint
- implements VFSEndpointType
An endpoint which receives messages from the NMR and writes the message to
the virtual file system.
- Author:
- lhein
|
Method Summary |
org.apache.commons.vfs.FileSystemManager |
getFileSystemManager()
|
org.apache.servicemix.components.util.FileMarshaler |
getMarshaler()
|
java.lang.String |
getPath()
|
protected void |
processInOnly(javax.jbi.messaging.MessageExchange exchange,
javax.jbi.messaging.NormalizedMessage in)
|
protected void |
resolvePath()
resolves the given path to a file object |
void |
setFileSystemManager(org.apache.commons.vfs.FileSystemManager fileSystemManager)
sets the file system manager |
void |
setMarshaler(org.apache.servicemix.components.util.FileMarshaler marshaler)
Specifies a FileMarshaler object that will marshal file data
into the NMR. |
void |
setPath(java.lang.String path)
Specifies a String object representing the path of the
file/folder to be polled.
Examples:
file:///home/lhein/pollFolder
zip:file:///home/lhein/pollFolder/myFile.zip
jar:http://www.myhost.com/files/Examples.jar
jar:../lib/classes.jar!/META-INF/manifest.mf
tar:gz:http://anyhost/dir/mytar.tar.gz!/mytar.tar!/path/in/tar/README.txt
tgz:file://anyhost/dir/mytar.tgz!/somepath/somefile
gz:/my/gz/file.gz
http://myusername@somehost/index.html
webdav://somehost:8080/dist
ftp://myusername:mypassword@somehost/pub/downloads/somefile.tgz
sftp://myusername:mypassword@somehost/pub/downloads/somefile.tgz
smb://somehost/home
tmp://dir/somefile.txt
res:path/in/classpath/image.png
ram:///any/path/to/file.txt
mime:file:///your/path/mail/anymail.mime!/filename.pdf
For further details have a look at http://commons.apache.org/vfs/filesystems.html. |
| Methods inherited from class org.apache.servicemix.common.endpoints.AbstractEndpoint |
getDefinition, getDescription, getEndpoint, getInterfaceName, getKey, getService, getServiceUnit, isExchangeOkay, prepareExchange, setDefinition, setDescription, setEndpoint, setInterfaceName, setService, setServiceUnit, toString, validate |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
VFSSendingEndpoint
public VFSSendingEndpoint()
resolvePath
protected void resolvePath()
throws java.lang.Exception
- resolves the given path to a file object
- Throws:
java.lang.Exception
processInOnly
protected void processInOnly(javax.jbi.messaging.MessageExchange exchange,
javax.jbi.messaging.NormalizedMessage in)
throws java.lang.Exception
- Overrides:
processInOnly in class ProviderEndpoint
- Throws:
java.lang.Exception
setPath
public void setPath(java.lang.String path)
- Specifies a
String object representing the path of the
file/folder to be polled.
Examples:
- file:///home/lhein/pollFolder
- zip:file:///home/lhein/pollFolder/myFile.zip
- jar:http://www.myhost.com/files/Examples.jar
- jar:../lib/classes.jar!/META-INF/manifest.mf
- tar:gz:http://anyhost/dir/mytar.tar.gz!/mytar.tar!/path/in/tar/README.txt
- tgz:file://anyhost/dir/mytar.tgz!/somepath/somefile
- gz:/my/gz/file.gz
- http://myusername@somehost/index.html
- webdav://somehost:8080/dist
- ftp://myusername:mypassword@somehost/pub/downloads/somefile.tgz
- sftp://myusername:mypassword@somehost/pub/downloads/somefile.tgz
- smb://somehost/home
- tmp://dir/somefile.txt
- res:path/in/classpath/image.png
- ram:///any/path/to/file.txt
- mime:file:///your/path/mail/anymail.mime!/filename.pdf
For further details have a look at http://commons.apache.org/vfs/filesystems.html.
- Parameters:
path - a String object that represents a file/folder/vfs
getPath
public java.lang.String getPath()
setFileSystemManager
public void setFileSystemManager(org.apache.commons.vfs.FileSystemManager fileSystemManager)
- sets the file system manager
- Parameters:
fileSystemManager - the file system manager
getFileSystemManager
public org.apache.commons.vfs.FileSystemManager getFileSystemManager()
setMarshaler
public void setMarshaler(org.apache.servicemix.components.util.FileMarshaler marshaler)
- Specifies a
FileMarshaler object that will marshal file data
into the NMR. The default file marshaller can read valid XML data.
FileMarshaler objects are implementations of
org.apache.servicemix.components.util.FileMarshaler.
- Parameters:
marshaler - a FileMarshaler object that can read data
from the file system.
getMarshaler
public org.apache.servicemix.components.util.FileMarshaler getMarshaler()
Copyright © 2005-2011 FuseSource. All Rights Reserved.