|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.sf.freecol.server.control.InputHandler.CurrentPlayerNetworkRequestHandler
abstract class InputHandler.CurrentPlayerNetworkRequestHandler
A network request handler for the current player will automatically return an error ("not your turn") if called by a connection other than that of the currently active player. If no game is active or if the player is unknown the same error is returned.
| Constructor Summary | |
|---|---|
InputHandler.CurrentPlayerNetworkRequestHandler()
|
|
| Method Summary | |
|---|---|
org.w3c.dom.Element |
handle(Connection conn,
org.w3c.dom.Element element)
Handle a request represented by an Element and return another
Element or null as the answer. |
protected abstract org.w3c.dom.Element |
handle(Player player,
Connection conn,
org.w3c.dom.Element element)
Handle a request for the current player. |
private boolean |
isCurrentPlayer(Player player)
Check if a player is the current player. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
InputHandler.CurrentPlayerNetworkRequestHandler()
| Method Detail |
|---|
public final org.w3c.dom.Element handle(Connection conn,
org.w3c.dom.Element element)
InputHandler.NetworkRequestHandlerElement and return another
Element or null as the answer.
handle in interface InputHandler.NetworkRequestHandlerconn - The message's Connection.element - The root element of the message.
private boolean isCurrentPlayer(Player player)
player - The player.
protected abstract org.w3c.dom.Element handle(Player player,
Connection conn,
org.w3c.dom.Element element)
player - The player.conn - The connection.element - The element with the request.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||