org.mule.endpoint
Class DynamicOutboundEndpoint
java.lang.Object
org.mule.endpoint.DynamicURIOutboundEndpoint
org.mule.endpoint.DynamicOutboundEndpoint
- All Implemented Interfaces:
- 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
| 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 |
DYNAMIC_URI_PLACEHOLDER
public static final String DYNAMIC_URI_PLACEHOLDER
- See Also:
- Constant Field Values
logger
protected final transient Log logger
- logger used by this class
uriTemplate
protected String uriTemplate
- The URI template used to construct the actual URI to send the message to.
DynamicOutboundEndpoint
public DynamicOutboundEndpoint(MuleContext muleContext,
EndpointBuilder builder,
String uriTemplate)
throws MalformedEndpointException
- Throws:
MalformedEndpointException
getAddress
public 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(String uri)
throws MalformedEndpointException
- Throws:
MalformedEndpointException
getEndpointURIForMessage
protected EndpointURI getEndpointURIForMessage(MuleEvent event)
throws DispatchException
- Throws:
DispatchException
parseURIString
protected String parseURIString(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(Object o)
- Overrides:
equals in class DynamicURIOutboundEndpoint
hashCode
public int hashCode()
- Overrides:
hashCode in class DynamicURIOutboundEndpoint
Copyright © 2003-2010 MuleSoft, Inc.. All Rights Reserved.