|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.caucho.network.balance.ClientNetworkState
public class ClientNetworkState
State of a network connection to a target server.
Constructor Summary | |
---|---|
ClientNetworkState(java.lang.String id,
long recoverTimeout)
|
Method Summary | |
---|---|
void |
close()
Close the client |
void |
completeConnection()
|
void |
disable()
Disable the client. |
void |
enable()
Enable the client. |
java.lang.String |
getId()
Returns the user-readable id of the target server. |
long |
getRecoverTimeout()
Return the max recover time. |
java.lang.String |
getState()
Returns the lifecycle state. |
boolean |
isActive()
Returns true if the server is active. |
boolean |
isDead()
Returns true if the server is dead. |
boolean |
isEnabled()
Return true if enabled. |
void |
onFail()
Called when the connection fails. |
void |
onSuccess()
Called when the server has a successful response |
boolean |
startConnection()
Start a new connection. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ClientNetworkState(java.lang.String id, long recoverTimeout)
Method Detail |
---|
public java.lang.String getId()
public long getRecoverTimeout()
public final java.lang.String getState()
public final boolean isActive()
public boolean isEnabled()
public final boolean isDead()
public void enable()
public void disable()
public void onSuccess()
public void onFail()
public boolean startConnection()
public void completeConnection()
public void close()
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |