org.moock.unity.core
Interface ServerServices


public interface ServerServices

Interface for handling services associated with Server.

Author:
Derek Clayton
See Also:
Services

Method Summary
 void broadcastServer(java.lang.String message)
          Broadcasts the message to all clients connected to the server.
 void broadcastServerButClient(java.lang.String butClientID, java.lang.String message)
          Broadcasts the message to all clients connected to the server except for the specified client.
 int getClientTimeout()
          Returns the time in minutes that an inactive client is removed from the server.
 java.lang.Object getServerAttribute(java.lang.String name)
          Gets a ServerSetting.
 long getUnityStartTime()
          Retrieves the server start time.
 java.lang.String getUnityVersion()
          Returns the version of Unity.
 void removeServerAttribute(java.lang.String name)
          Removes a ServerSetting.
 void setServerAttribute(java.lang.String name, java.lang.Object value)
          Sets a ServerSetting.
 

Method Detail

getUnityVersion

public java.lang.String getUnityVersion()
Returns the version of Unity.

getClientTimeout

public int getClientTimeout()
Returns the time in minutes that an inactive client is removed from the server.

getUnityStartTime

public long getUnityStartTime()
Retrieves the server start time.
Returns:
the difference, measured in milliseconds, between the time Unity started and midnight, January 1, 1970 UTC.

getServerAttribute

public java.lang.Object getServerAttribute(java.lang.String name)
Gets a ServerSetting.

setServerAttribute

public void setServerAttribute(java.lang.String name,
                               java.lang.Object value)
Sets a ServerSetting.

removeServerAttribute

public void removeServerAttribute(java.lang.String name)
Removes a ServerSetting.

broadcastServer

public void broadcastServer(java.lang.String message)
Broadcasts the message to all clients connected to the server.

broadcastServerButClient

public void broadcastServerButClient(java.lang.String butClientID,
                                     java.lang.String message)
Broadcasts the message to all clients connected to the server except for the specified client.
Parameters:
butClientID - the client omitted from the broadcast