Package com.adaptris.core
Interface ConnectionErrorHandler
-
- All Superinterfaces:
ComponentLifecycle
- All Known Implementing Classes:
ActiveJmsConnectionErrorHandler,ChannelCloseErrorHandler,ConnectionErrorHandlerImp,JmsConnectionErrorHandler,JmsConnectionErrorHandlerImpl,NullConnectionErrorHandler
public interface ConnectionErrorHandler extends ComponentLifecycle
Implementations of this class encapsualte behaviour that is invoked when an
Exceptionrelating to a connection is encountered.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleanallowedInConjunctionWith(ConnectionErrorHandler ceh)Is this error handler allowed to work with this error handler.voidhandleConnectionException()Handle the error.voidregisterConnection(AdaptrisConnection connection)Sets theAdaptrisConnectionto handle errors for.<T> TretrieveConnection(java.lang.Class<T> type)Return this components underlying connection.-
Methods inherited from interface com.adaptris.core.ComponentLifecycle
close, init, start, stop
-
-
-
-
Method Detail
-
registerConnection
void registerConnection(AdaptrisConnection connection)
Sets the
AdaptrisConnectionto handle errors for.- Parameters:
connection- theAdaptrisConnectionto handle errors for
-
retrieveConnection
<T> T retrieveConnection(java.lang.Class<T> type)
Return this components underlying connection.- Parameters:
type- the type of connection- Returns:
- the connection
-
allowedInConjunctionWith
boolean allowedInConjunctionWith(ConnectionErrorHandler ceh)
Is this error handler allowed to work with this error handler.- Parameters:
ceh- other error handler.- Returns:
- true if the two error handlers can work together.
-
handleConnectionException
void handleConnectionException()
Handle the error.
-
-