org.mule.transport.service
Class TransportFactory
java.lang.Object
org.mule.transport.service.TransportFactory
public class TransportFactory
- extends Object
TransportFactory
can be used for generically creating endpoints
from an url. Note that for some endpoints, the url alone is not enough to create
the endpoint if a connector for the endpoint has not already been configured with
the Mule Manager.
Field Summary |
protected static Log |
logger
logger used by this class |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
logger
protected static final Log logger
- logger used by this class
TransportFactory
public TransportFactory()
createConnector
public static Connector createConnector(EndpointURI url,
MuleContext muleContext)
throws TransportFactoryException
- Creates an uninitialied connector from the provided MuleEndpointURI. The
scheme is used to determine what kind of connector to create. Any params set
on the uri can be used to initialise bean properties on the created connector.
Note that the initalise method will need to be called on the connector
returned. This is so that developers can control when the connector
initialisation takes place as this is likely to initialse all connecotr
resources.
- Parameters:
url
- the MuleEndpointURI url to create the connector with
- Returns:
- a new Connector
- Throws:
TransportFactoryException
getOrCreateConnectorByProtocol
public static Connector getOrCreateConnectorByProtocol(ImmutableEndpoint endpoint,
MuleContext muleContext)
throws TransportFactoryException
- Throws:
TransportFactoryException
getOrCreateConnectorByProtocol
public static Connector getOrCreateConnectorByProtocol(EndpointURI uri,
MuleContext muleContext)
throws TransportFactoryException
- Returns an initialized connector.
- Throws:
TransportFactoryException
getConnectorByProtocol
public static Connector getConnectorByProtocol(String protocol)
Copyright © 2003-2009 MuleSource, Inc.. All Rights Reserved.