|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface MessagePasser
A global class passing messages between players.
Method Summary | |
---|---|
void |
quit(int clientServerRole)
Notifies listeners that a player wants to quit, and unregisters that player. |
void |
registerGameController(GameController c,
int clientServerRole)
Registers a local game controller, such that it may receive messages. |
void |
sendMessage(int messageNumber,
java.lang.String message)
Used for sending move messages between game controllers. |
void |
talk(int clientServerRole,
java.lang.String message)
Used for sending chat messages to the other player. |
Method Detail |
---|
void registerGameController(GameController c, int clientServerRole) throws java.rmi.RemoteException
c
- A game controllerclientServerRole
- The role of the game controller
java.rmi.RemoteException
void sendMessage(int messageNumber, java.lang.String message) throws java.rmi.RemoteException
messageNumber
- A message numbermessage
- An encoded message
java.rmi.RemoteException
Protocol
void quit(int clientServerRole) throws java.rmi.RemoteException
java.rmi.RemoteException
void talk(int clientServerRole, java.lang.String message) throws java.rmi.RemoteException
clientServerRole
- The role of the player sending a message, used to identify
the othermessage
- The message
java.rmi.RemoteException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |