|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface IDelegateBridge
A class that communicates with the Delegate. DelegateBridge co-ordinates comunication between the Delegate and both the players and the game data. The reason for communicating through a DelegateBridge is to achieve network transparancy. The delegateBridge allows the Delegate to talk to the player in a safe manner.
| Method Summary | |
|---|---|
void |
addChange(Change aChange)
Add a change to game data. |
void |
enterDelegateExecution()
|
IChannelSubscribor |
getDisplayChannelBroadcaster()
Return an object that implements the IDisplay interface for the game. |
IDelegateHistoryWriter |
getHistoryWriter()
return the delegate history writer for this game. |
PlayerID |
getPlayerID()
|
int[] |
getRandom(int max,
int count,
java.lang.String annotation)
Return a random value to be used by the delegate. |
int |
getRandom(int max,
java.lang.String annotation)
equivalent to getRandom(max,1,annotation)[0] |
IRemote |
getRemote()
equivalent to getRemote(getPlayerID()) |
IRemote |
getRemote(PlayerID id)
Get a remote reference to the given player. |
java.lang.String |
getStepName()
Returns the current step name |
java.util.Properties |
getStepProperties()
|
void |
leaveDelegateExecution()
|
void |
stopGameSequence()
After this step finishes executing, the next delegate will not be called. |
| Method Detail |
|---|
IRemote getRemote()
IRemote getRemote(PlayerID id)
IRemoteMessengerPlayerID getPlayerID()
java.lang.String getStepName()
void addChange(Change aChange)
aChange -
int getRandom(int max,
java.lang.String annotation)
int[] getRandom(int max,
int count,
java.lang.String annotation)
Delegates should not use random data that comes from any other source.
annotation - -
a string used to describe the random event.IDelegateHistoryWriter getHistoryWriter()
The delegate history writer allows writing to the game history.
IChannelSubscribor getDisplayChannelBroadcaster()
Methods called on this returned object will be invoked on all displays in the game, including those on remote machines
java.util.Properties getStepProperties()
void stopGameSequence()
This methd allows the delegate to signal that the game is over, but does not force the ui or the display to shutdown.
void leaveDelegateExecution()
void enterDelegateExecution()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||