public interface MessageReceiver extends Connectable, MessageSource
MessageReceiver is used to receive data from an external system.
Typically an implementation of this interface will also implement the listener
interface for the external system. For example to listen to a JMS destination the
developer would also implement javax.jms.MessageListener. The endpoint (which
creates the MessageReceiver) will then register the receiver with the JMS
server. Where a listener interface is not availiable the derived
MessageReceiver will implement the code necessary to receive
data from the external system. For example, the file endpoint will poll a
specified directory for its data.PHASE_NAMEPHASE_NAMEPHASE_NAMEPHASE_NAME| Modifier and Type | Method and Description |
|---|---|
MuleMessage |
createMuleMessage(Object transportMessage) |
MuleMessage |
createMuleMessage(Object transportMessage,
String encoding) |
InboundEndpoint |
getEndpoint() |
EndpointURI |
getEndpointURI()
The endpointUri that this receiver listens on
|
FlowConstruct |
getFlowConstruct() |
String |
getReceiverKey() |
MuleEvent |
routeMessage(MuleMessage message) |
MuleEvent |
routeMessage(MuleMessage message,
Transaction trans) |
MuleEvent |
routeMessage(MuleMessage message,
Transaction trans,
OutputStream outputStream) |
void |
setEndpoint(InboundEndpoint endpoint) |
void |
setReceiverKey(String key) |
connect, disconnect, getConnectionDescription, isConnected, validateConnectioninitialisedisposesetListenerInboundEndpoint getEndpoint()
FlowConstruct getFlowConstruct()
void setEndpoint(InboundEndpoint endpoint)
endpoint - the endpoint to listen onImmutableEndpointEndpointURI getEndpointURI()
String getReceiverKey()
void setReceiverKey(String key)
MuleEvent routeMessage(MuleMessage message) throws MuleException
MuleExceptionMuleEvent routeMessage(MuleMessage message, Transaction trans) throws MuleException
MuleExceptionMuleEvent routeMessage(MuleMessage message, Transaction trans, OutputStream outputStream) throws MuleException
MuleExceptionMuleMessage createMuleMessage(Object transportMessage, String encoding) throws MuleException
MuleExceptionMuleMessage createMuleMessage(Object transportMessage) throws MuleException
MuleExceptionCopyright © 2003–2015 MuleSoft, Inc.. All rights reserved.