com.toremote.gateway.connection
Interface ServerListInterface

All Superinterfaces:
java.lang.Cloneable
All Known Implementing Classes:
AbstractServerList

public interface ServerListInterface
extends java.lang.Cloneable


Field Summary
static java.lang.String TYPE_BLACK_LIST
           
static java.lang.String TYPE_NORMAL_LIST
           
static java.lang.String TYPE_WHITE_LIST
           
 
Method Summary
 Connection getConnectionById(java.lang.String id)
           
 Connection getConnectionByIdOrServer(java.lang.String idOrServer)
           
 java.lang.String getListType()
           
 boolean isAllowed(java.lang.String server)
           
 boolean isDisplay()
           
 boolean modifiedSince(long time)
           
 java.lang.String toJson()
           
 

Field Detail

TYPE_WHITE_LIST

static final java.lang.String TYPE_WHITE_LIST
See Also:
Constant Field Values

TYPE_BLACK_LIST

static final java.lang.String TYPE_BLACK_LIST
See Also:
Constant Field Values

TYPE_NORMAL_LIST

static final java.lang.String TYPE_NORMAL_LIST
See Also:
Constant Field Values
Method Detail

getConnectionById

Connection getConnectionById(java.lang.String id)
Parameters:
id: - server id
Returns:
Connection object, null if not found

getConnectionByIdOrServer

Connection getConnectionByIdOrServer(java.lang.String idOrServer)
Parameters:
idOrServer: - server id or name
Returns:
Connection object, null if not found

getListType

java.lang.String getListType()
Returns:
TYPE_WHITE_LIST, TYPE_BLACK_LIST or TYPE_NORMAL_LIST

isAllowed

boolean isAllowed(java.lang.String server)
Parameters:
server: - server id or server name
Returns:
true if this server can be accessed.

modifiedSince

boolean modifiedSince(long time)
Parameters:
time -
Returns:
true if the server list is modified since the given time

isDisplay

boolean isDisplay()
Returns:
true if you want user see this list

toJson

java.lang.String toJson()