cz.cuni.amis.pogamut.ut2004.communication.messages.gbcommands
Class SetLock

java.lang.Object
  extended by cz.cuni.amis.pogamut.base.communication.messages.CommandMessage
      extended by cz.cuni.amis.pogamut.ut2004.communication.messages.gbcommands.SetLock

public class SetLock
extends CommandMessage

Representation of the GameBots2004 command SETLOCK. Will disable new connections to bot server and or control server - depends on parameters. If last ControlServer instance is leaving. ControlServer lock will be canceled.


Field Summary
protected  java.lang.Boolean BotServer
          If BotConnections should be locked.
protected  java.lang.Boolean ControlServer
          If ControlConnections (server connections) should be locked.
static java.lang.String PROTOTYPE
          Example how the message looks like - used during parser tests.
 
Constructor Summary
SetLock()
          Creates new instance of command SetLock.
SetLock(java.lang.Boolean BotServer, java.lang.Boolean ControlServer)
          Creates new instance of command SetLock.
SetLock(SetLock original)
          Cloning constructor.
 
Method Summary
 java.lang.Boolean isBotServer()
          If BotConnections should be locked.
 java.lang.Boolean isControlServer()
          If ControlConnections (server connections) should be locked.
 SetLock setBotServer(java.lang.Boolean BotServer)
          If BotConnections should be locked.
 SetLock setControlServer(java.lang.Boolean ControlServer)
          If ControlConnections (server connections) should be locked.
 java.lang.String toHtmlString()
           
 java.lang.String toMessage()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

PROTOTYPE

public static final java.lang.String PROTOTYPE
Example how the message looks like - used during parser tests.

See Also:
Constant Field Values

BotServer

protected java.lang.Boolean BotServer
If BotConnections should be locked.


ControlServer

protected java.lang.Boolean ControlServer
If ControlConnections (server connections) should be locked.

Constructor Detail

SetLock

public SetLock(java.lang.Boolean BotServer,
               java.lang.Boolean ControlServer)
Creates new instance of command SetLock. Will disable new connections to bot server and or control server - depends on parameters. If last ControlServer instance is leaving. ControlServer lock will be canceled. Corresponding GameBots message for this command is SETLOCK.

Parameters:
BotServer - If BotConnections should be locked.
ControlServer - If ControlConnections (server connections) should be locked.

SetLock

public SetLock()
Creates new instance of command SetLock. Will disable new connections to bot server and or control server - depends on parameters. If last ControlServer instance is leaving. ControlServer lock will be canceled. Corresponding GameBots message for this command is SETLOCK.

WARNING: this is empty-command constructor, you have to use setters to fill it up with data that should be sent to GameBots2004!


SetLock

public SetLock(SetLock original)
Cloning constructor.

Parameters:
original -
Method Detail

isBotServer

public java.lang.Boolean isBotServer()
If BotConnections should be locked.


setBotServer

public SetLock setBotServer(java.lang.Boolean BotServer)
If BotConnections should be locked.


isControlServer

public java.lang.Boolean isControlServer()
If ControlConnections (server connections) should be locked.


setControlServer

public SetLock setControlServer(java.lang.Boolean ControlServer)
If ControlConnections (server connections) should be locked.


toString

public java.lang.String toString()
Overrides:
toString in class CommandMessage

toHtmlString

public java.lang.String toHtmlString()

toMessage

public java.lang.String toMessage()