|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectbass.crawler.ClientRegistration
public class ClientRegistration
ServerSide Object to register working clients, so we're able to restart timed out clients
| Field Summary | |
|---|---|
private java.util.LinkedList<DTO_Client> |
clients
|
private static int |
timeOutTime
|
| Constructor Summary | |
|---|---|
ClientRegistration()
generates an empty client registration object |
|
| Method Summary | |
|---|---|
void |
addClient(java.lang.String clientIp)
adds a client with the specified ip to the registry, lastSeen time is set to current time |
java.util.LinkedList<DTO_Client> |
getRegisteredClients()
|
java.lang.String[] |
getTimedOutClients()
generates a list of timed out clients |
static int |
getTimeOutTime()
|
void |
seenClient(java.lang.String clientIp)
updates the lastSeen time of the specified client with the current time if client is not in list it will be automaticly added |
void |
unregisterClient(java.lang.String clientIP)
removes a client from the registered clients list |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private static final int timeOutTime
private java.util.LinkedList<DTO_Client> clients
| Constructor Detail |
|---|
public ClientRegistration()
| Method Detail |
|---|
public void addClient(java.lang.String clientIp)
clientIp - the clients ippublic void seenClient(java.lang.String clientIp)
clientIp - the clients ippublic java.lang.String[] getTimedOutClients()
public java.util.LinkedList<DTO_Client> getRegisteredClients()
public void unregisterClient(java.lang.String clientIP)
clientIP - the clients ippublic static int getTimeOutTime()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||