org.mule.endpoint
Class DynamicOutboundEndpoint
java.lang.Object
org.mule.endpoint.DynamicURIOutboundEndpoint
org.mule.endpoint.DynamicOutboundEndpoint
- All Implemented Interfaces:
- java.io.Serializable, ImmutableEndpoint, OutboundEndpoint, MessageProcessor
- Direct Known Subclasses:
- CallOutboundEndpoint
public class DynamicOutboundEndpoint
- extends DynamicURIOutboundEndpoint
An Outbound endpoint who's URI will be constructed based on the current message.
This allows for the destination of a message to change based on the contents of
the message. Note that this endpoint ONLY substitutes the URI, but other config
elements such as the connector (and scheme), transformers, filters, etc do not
change. You cannot change an endpoint scheme dynamically so you can't switch
between HTTP and JMS for example using the same dynamic endpoint.
- See Also:
- Serialized Form
Field Summary |
static java.lang.String |
DYNAMIC_URI_PLACEHOLDER
|
protected Log |
logger
logger used by this class |
protected java.lang.String |
uriTemplate
The URI template used to construct the actual URI to send the message to. |
Methods inherited from class org.mule.endpoint.DynamicURIOutboundEndpoint |
getConnector, getEncoding, getEndpointBuilderName, getEndpointURI, getExchangePattern, getFilter, getInitialState, getMessageProcessors, getMessageProcessorsFactory, getMimeType, getMuleContext, getName, getProperties, getProperty, getProtocol, getResponseMessageProcessors, getResponseProperties, getResponseTimeout, getResponseTransformers, getRetryPolicyTemplate, getSecurityFilter, getTransactionConfig, getTransformers, isDeleteUnacceptedMessages, isDisableTransportTransformer, isProtocolSupported, isReadOnly, setEndpointURI |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
DYNAMIC_URI_PLACEHOLDER
public static final java.lang.String DYNAMIC_URI_PLACEHOLDER
- See Also:
- Constant Field Values
logger
protected final transient Log logger
- logger used by this class
uriTemplate
protected java.lang.String uriTemplate
- The URI template used to construct the actual URI to send the message to.
DynamicOutboundEndpoint
public DynamicOutboundEndpoint(MuleContext muleContext,
EndpointBuilder builder,
java.lang.String uriTemplate)
throws MalformedEndpointException
- Throws:
MalformedEndpointException
getAddress
public java.lang.String getAddress()
- Description copied from interface:
ImmutableEndpoint
- This returns the address of the endpoint. When this contains a template, it may not be a URI
- Specified by:
getAddress
in interface ImmutableEndpoint
- Overrides:
getAddress
in class DynamicURIOutboundEndpoint
- Returns:
- the address on which the endpoint sends or receives data
validateUriTemplate
protected void validateUriTemplate(java.lang.String uri)
throws MalformedEndpointException
- Throws:
MalformedEndpointException
getEndpointURIForMessage
protected EndpointURI getEndpointURIForMessage(MuleEvent event)
throws DispatchException
- Throws:
DispatchException
parseURIString
protected java.lang.String parseURIString(java.lang.String uri,
MuleMessage message)
process
public MuleEvent process(MuleEvent event)
throws MuleException
- Description copied from interface:
MessageProcessor
- Invokes the MessageProcessor.
- Specified by:
process
in interface MessageProcessor
- Overrides:
process
in class DynamicURIOutboundEndpoint
- Parameters:
event
- MuleEvent to be processed
- Returns:
- optional response MuleEvent
- Throws:
MuleException
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in class DynamicURIOutboundEndpoint
hashCode
public int hashCode()
- Overrides:
hashCode
in class DynamicURIOutboundEndpoint
Copyright © 2003-2010 MuleSoft, Inc.. All Rights Reserved.