|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectheurgame.GameServer
Field Summary | |
protected boolean |
active
|
Constructor Summary | |
GameServer(java.lang.String hostname,
int port,
Game thisGame,
Referee official)
Constructs a new GameServer |
Method Summary | |
java.lang.String |
getGameName()
|
int |
getMinimumPlayers()
|
java.lang.String |
getServerAddress()
|
boolean |
isActive()
|
void |
makeHuClient(java.lang.String name)
Delegates the creation of a HuClient, a human client to the server. |
void |
reorderPlayers(PlayerToken[] newOrder)
Called to reorder the current connected players |
void |
reset()
Called to disconnect all connected players from the game. |
void |
run()
Actual guts of the Server code. |
void |
stopServer()
Causes the Server spinloop to gracefully halt. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected volatile boolean active
Constructor Detail |
public GameServer(java.lang.String hostname, int port, Game thisGame, Referee official)
hostname
- for the server to bindport
- also for bindingthisGame
- allowing the proper construction of Game Specific HuClients and PlayerProxiesofficial
- Referees are involved in all player related transactionsMethod Detail |
public void run()
run
in interface java.lang.Runnable
Runnable.run()
public void reorderPlayers(PlayerToken[] newOrder)
newOrder
- New Established Orderpublic void reset()
public void makeHuClient(java.lang.String name)
name
- of the clientpublic int getMinimumPlayers()
public java.lang.String getServerAddress()
public java.lang.String getGameName()
public boolean isActive()
public void stopServer()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |