public abstract class AbstractConnectable extends Object implements Connectable, ExceptionListener
Modifier and Type | Field and Description |
---|---|
protected boolean |
connected |
protected boolean |
connecting |
protected ConnectionStrategy |
connectionStrategy |
protected AbstractConnector |
connector |
protected boolean |
disposed |
protected ImmutableEndpoint |
endpoint |
protected org.apache.commons.logging.Log |
logger
logger used by this class
|
Constructor and Description |
---|
AbstractConnectable(ImmutableEndpoint endpoint) |
Modifier and Type | Method and Description |
---|---|
void |
activate() |
void |
connect()
Make the connection to the underlying transport.
|
void |
disconnect()
Disconnect the from the underlying transport
|
void |
dispose()
Template method to destroy any resources held by the Message Dispatcher
|
protected void |
disposeAndLogException() |
protected abstract void |
doConnect() |
protected abstract void |
doDisconnect() |
protected abstract void |
doDispose() |
void |
exceptionThrown(Exception e) |
protected String |
getConnectEventId(ImmutableEndpoint endpoint) |
String |
getConnectionDescription()
Returns a string identifying the underlying resource
|
Connector |
getConnector() |
ImmutableEndpoint |
getEndpoint() |
boolean |
isConnected()
Determines if this object is connected or not
|
protected boolean |
isDoThreading() |
void |
passivate() |
void |
reconnect() |
String |
toString() |
boolean |
validate() |
protected transient org.apache.commons.logging.Log logger
protected final ImmutableEndpoint endpoint
protected final AbstractConnector connector
protected boolean disposed
protected ConnectionStrategy connectionStrategy
protected volatile boolean connecting
protected volatile boolean connected
public AbstractConnectable(ImmutableEndpoint endpoint)
protected void disposeAndLogException()
public void exceptionThrown(Exception e)
exceptionThrown
in interface ExceptionListener
public boolean validate()
public void activate()
public void passivate()
public final void dispose()
public Connector getConnector()
public ImmutableEndpoint getEndpoint()
public void connect() throws Exception
Connectable
connect
in interface Connectable
Exception
public void disconnect() throws Exception
Connectable
disconnect
in interface Connectable
Exception
protected String getConnectEventId(ImmutableEndpoint endpoint)
public final boolean isConnected()
Connectable
isConnected
in interface Connectable
protected boolean isDoThreading()
public String getConnectionDescription()
getConnectionDescription
in interface Connectable
protected abstract void doDispose()
Copyright © 2003–2013 MuleSource, Inc.. All rights reserved.