|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.ifeth.sehr.client.api.driver.ConnectionInfo
| Constructor Summary | |
ConnectionInfo()
|
|
ConnectionInfo(long t0)
Constructor with setting the start-up time |
|
| Method Summary | |
void |
close()
Close connection by setting a 'close request' |
double |
getCurrentDurationTime()
Track current duration time A watching thread can use this to show the 'uptime' |
double |
getLastConnectionTime()
Get stored last connection (uptime) |
java.lang.Object |
getObject()
Returns the object associated with the connection |
int |
getStatus()
Get the status Note: If '0' a watcher or listener thread can close the connection |
double |
getTotalConnectionTime()
Get stored total connection time |
boolean |
isCloseRequest()
Get the flag 'close requested' This is a very important flag. |
void |
setCloseRequest(boolean closeRequest)
Set a 'close requested' |
void |
setDownTimeMillis(long t1)
Set 'down-time' |
void |
setStartUpTimeMillis(long t0)
Set startup time; if arg <=0 set to current time |
void |
setStatus(int code)
Flag the status of the connection 0=unused/offline, 1=used/online/stay online, -1=failure |
void |
setTotalConnectionTime(double total)
Used on reconnections to add total connection times |
void |
storeObject(java.lang.Object o)
Store (track) object associated with the connection, e.g. that invoked the connection to keep some parameters |
java.lang.String |
toString()
For debugging/logging purposes: some infos as string |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public ConnectionInfo()
public ConnectionInfo(long t0)
t0 - if ≤ 0 set to current time| Method Detail |
public void storeObject(java.lang.Object o)
public java.lang.Object getObject()
public void setStatus(int code)
0=unused/offline, 1=used/online/stay online, -1=failure
public int getStatus()
Note: If '0' a watcher or listener thread can close the connection
public double getCurrentDurationTime()
A watching thread can use this to show the 'uptime'
public void setStartUpTimeMillis(long t0)
public void setDownTimeMillis(long t1)
public double getLastConnectionTime()
public double getTotalConnectionTime()
public void setTotalConnectionTime(double total)
public boolean isCloseRequest()
This is a very important flag. If a handler/thread requests a 'close connection' no other handler should use this connection; it will be down after a few moments/system tics after all pending stuff is done!
public void close()
public void setCloseRequest(boolean closeRequest)
public java.lang.String toString()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||