|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Control
Method Summary | |
---|---|
void |
closeTransporter(java.lang.String duringException)
Closes the connection to the underlying transport. |
java.lang.String |
getConnectionFailedException()
getConnectionFailedException() should be checked by isConnectionAlive() before any attempt
to "ping" the server, and if the result is non-null the connection may be assumed to be dead,
with the string value containing a description of the reason, if any, for the failure. |
boolean |
isConnectionAlive()
Check whether the connection is alive (and is not closing) or has failed. |
boolean |
isConnectionClosing()
Returns true if a connection is being closed |
boolean |
isPaused()
Returns true after pauseTransporter() has been called. |
boolean |
isRunning()
Check if the transporter is running and trying to process messages. |
boolean |
isStopping()
Check if the transporter is trying to stop. |
void |
pauseTransporter()
Pause reception of messages. |
void |
resumeTransporter()
Resume reception of messages after a pause. |
void |
setConnectionFailedException(java.lang.String exception)
Use setConnectionFailedException() to notify connection failures. |
void |
startTransporter()
Start listening for, or sending, messages. |
void |
stopTransporter()
Stop listening for messages. |
Method Detail |
---|
void startTransporter() throws IbafException
IbafException
void stopTransporter() throws IbafException
IbafException
void pauseTransporter() throws IbafException
Temporarily stops the transporter's delivery of incoming messages.
It can be restarted using the resumeTransporter()
method.
The underlying connection may continue to deliver some "in-flight" messages before the pause takes effect.
IbafException
- If problem pausing the transportervoid resumeTransporter() throws IbafException
IbafException
- If problem resuming the transportervoid closeTransporter(java.lang.String duringException) throws IbafException
duringException
- Set non-null if closeTransporter() called as a result of exception handling.
If any exceptions occur during the close operation, the value is appended to the error message.
IbafException
- If problem resuming the transporterboolean isPaused()
This return value of this method used in situations where the underlying transport has no explicit means of pausing a particular connection. If it returns true, the transporter should continue to run, but not process messages.
boolean isConnectionAlive()
boolean isConnectionClosing()
boolean isRunning()
boolean isStopping()
void setConnectionFailedException(java.lang.String exception) throws IbafException
IbafException
java.lang.String getConnectionFailedException()
isConnectionAlive()
before any attempt
to "ping" the server, and if the result is non-null the connection may be assumed to be dead,
with the string value containing a description of the reason, if any, for the failure.
AbstractTransporter.setConnectionFailedException(String exception)
should therefore be called
with a null value when a fresh live connection is established.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |