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

Package class diagram package SendControlMessage
java.lang.Object
  extended by cz.cuni.amis.pogamut.base.communication.messages.CommandMessage
      extended by cz.cuni.amis.pogamut.ut2004.communication.messages.gbcommands.SendControlMessage

public class SendControlMessage
extends CommandMessage

Representation of the GameBots2004 command SENDCTRLMSG. Send a message to the all bots or just one bot. To be used for "protocol within protocol", not perfect, but suffices for now.


Field Summary
protected  UnrealId BotId
          Only valid for SendAll='false', here you can specify Id of the bot that should receive the message.
protected  Boolean PB1
          Param Boolean 1
protected  Boolean PB2
          Param Boolean 2
protected  Boolean PB3
          Param Boolean 3
protected  Double PF1
          Param Double 1
protected  Double PF2
          Param Double 2
protected  Double PF3
          Param Double 3
protected  Integer PI1
          Param Integer 1
protected  Integer PI2
          Param Integer 2
protected  Integer PI3
          Param Integer 3
static String PROTOTYPE
          Example how the message looks like - used during parser tests.
protected  String PS1
          Param String 1
protected  String PS2
          Param String 2
protected  String PS3
          Param String 3
protected  Boolean SendAll
          True - sends the message to ALL connected bots, False - sends to one bot specified within BotId.
protected  String Type
          Custom type of the message.
 
Constructor Summary
SendControlMessage()
          Creates new instance of command SendControlMessage.
SendControlMessage(Boolean SendAll, UnrealId BotId, String Type, String PS1, String PS2, String PS3, Integer PI1, Integer PI2, Integer PI3, Double PF1, Double PF2, Double PF3, Boolean PB1, Boolean PB2, Boolean PB3)
          Creates new instance of command SendControlMessage.
SendControlMessage(SendControlMessage original)
          Cloning constructor.
 
Method Summary
 UnrealId getBotId()
          Only valid for SendAll='false', here you can specify Id of the bot that should receive the message.
 Double getPF1()
          Param Double 1
 Double getPF2()
          Param Double 2
 Double getPF3()
          Param Double 3
 Integer getPI1()
          Param Integer 1
 Integer getPI2()
          Param Integer 2
 Integer getPI3()
          Param Integer 3
 String getPS1()
          Param String 1
 String getPS2()
          Param String 2
 String getPS3()
          Param String 3
 String getType()
          Custom type of the message.
 Boolean isPB1()
          Param Boolean 1
 Boolean isPB2()
          Param Boolean 2
 Boolean isPB3()
          Param Boolean 3
 Boolean isSendAll()
          True - sends the message to ALL connected bots, False - sends to one bot specified within BotId.
 SendControlMessage setBotId(UnrealId BotId)
          Only valid for SendAll='false', here you can specify Id of the bot that should receive the message.
 SendControlMessage setPB1(Boolean PB1)
          Param Boolean 1
 SendControlMessage setPB2(Boolean PB2)
          Param Boolean 2
 SendControlMessage setPB3(Boolean PB3)
          Param Boolean 3
 SendControlMessage setPF1(Double PF1)
          Param Double 1
 SendControlMessage setPF2(Double PF2)
          Param Double 2
 SendControlMessage setPF3(Double PF3)
          Param Double 3
 SendControlMessage setPI1(Integer PI1)
          Param Integer 1
 SendControlMessage setPI2(Integer PI2)
          Param Integer 2
 SendControlMessage setPI3(Integer PI3)
          Param Integer 3
 SendControlMessage setPS1(String PS1)
          Param String 1
 SendControlMessage setPS2(String PS2)
          Param String 2
 SendControlMessage setPS3(String PS3)
          Param String 3
 SendControlMessage setSendAll(Boolean SendAll)
          True - sends the message to ALL connected bots, False - sends to one bot specified within BotId.
 SendControlMessage setType(String Type)
          Custom type of the message.
 String toHtmlString()
           
 String toMessage()
           
 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 String PROTOTYPE
Example how the message looks like - used during parser tests.

See Also:
Constant Field Values

SendAll

protected Boolean SendAll
True - sends the message to ALL connected bots, False - sends to one bot specified within BotId.


BotId

protected UnrealId BotId
Only valid for SendAll='false', here you can specify Id of the bot that should receive the message.


Type

protected String Type
Custom type of the message.


PS1

protected String PS1
Param String 1


PS2

protected String PS2
Param String 2


PS3

protected String PS3
Param String 3


PI1

protected Integer PI1
Param Integer 1


PI2

protected Integer PI2
Param Integer 2


PI3

protected Integer PI3
Param Integer 3


PF1

protected Double PF1
Param Double 1


PF2

protected Double PF2
Param Double 2


PF3

protected Double PF3
Param Double 3


PB1

protected Boolean PB1
Param Boolean 1


PB2

protected Boolean PB2
Param Boolean 2


PB3

protected Boolean PB3
Param Boolean 3

Constructor Detail

SendControlMessage

public SendControlMessage(Boolean SendAll,
                          UnrealId BotId,
                          String Type,
                          String PS1,
                          String PS2,
                          String PS3,
                          Integer PI1,
                          Integer PI2,
                          Integer PI3,
                          Double PF1,
                          Double PF2,
                          Double PF3,
                          Boolean PB1,
                          Boolean PB2,
                          Boolean PB3)
Creates new instance of command SendControlMessage. Send a message to the all bots or just one bot. To be used for "protocol within protocol", not perfect, but suffices for now. Corresponding GameBots message for this command is SENDCTRLMSG.

Parameters:
SendAll - True - sends the message to ALL connected bots, False - sends to one bot specified within BotId.
BotId - Only valid for SendAll='false', here you can specify Id of the bot that should receive the message.
Type - Custom type of the message.
PS1 - Param String 1
PS2 - Param String 2
PS3 - Param String 3
PI1 - Param Integer 1
PI2 - Param Integer 2
PI3 - Param Integer 3
PF1 - Param Double 1
PF2 - Param Double 2
PF3 - Param Double 3
PB1 - Param Boolean 1
PB2 - Param Boolean 2
PB3 - Param Boolean 3

SendControlMessage

public SendControlMessage()
Creates new instance of command SendControlMessage. Send a message to the all bots or just one bot. To be used for "protocol within protocol", not perfect, but suffices for now. Corresponding GameBots message for this command is SENDCTRLMSG.

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


SendControlMessage

public SendControlMessage(SendControlMessage original)
Cloning constructor.

Parameters:
original -
Method Detail

isSendAll

public Boolean isSendAll()
True - sends the message to ALL connected bots, False - sends to one bot specified within BotId.


setSendAll

public SendControlMessage setSendAll(Boolean SendAll)
True - sends the message to ALL connected bots, False - sends to one bot specified within BotId.


getBotId

public UnrealId getBotId()
Only valid for SendAll='false', here you can specify Id of the bot that should receive the message.


setBotId

public SendControlMessage setBotId(UnrealId BotId)
Only valid for SendAll='false', here you can specify Id of the bot that should receive the message.


getType

public String getType()
Custom type of the message.


setType

public SendControlMessage setType(String Type)
Custom type of the message.


getPS1

public String getPS1()
Param String 1


setPS1

public SendControlMessage setPS1(String PS1)
Param String 1


getPS2

public String getPS2()
Param String 2


setPS2

public SendControlMessage setPS2(String PS2)
Param String 2


getPS3

public String getPS3()
Param String 3


setPS3

public SendControlMessage setPS3(String PS3)
Param String 3


getPI1

public Integer getPI1()
Param Integer 1


setPI1

public SendControlMessage setPI1(Integer PI1)
Param Integer 1


getPI2

public Integer getPI2()
Param Integer 2


setPI2

public SendControlMessage setPI2(Integer PI2)
Param Integer 2


getPI3

public Integer getPI3()
Param Integer 3


setPI3

public SendControlMessage setPI3(Integer PI3)
Param Integer 3


getPF1

public Double getPF1()
Param Double 1


setPF1

public SendControlMessage setPF1(Double PF1)
Param Double 1


getPF2

public Double getPF2()
Param Double 2


setPF2

public SendControlMessage setPF2(Double PF2)
Param Double 2


getPF3

public Double getPF3()
Param Double 3


setPF3

public SendControlMessage setPF3(Double PF3)
Param Double 3


isPB1

public Boolean isPB1()
Param Boolean 1


setPB1

public SendControlMessage setPB1(Boolean PB1)
Param Boolean 1


isPB2

public Boolean isPB2()
Param Boolean 2


setPB2

public SendControlMessage setPB2(Boolean PB2)
Param Boolean 2


isPB3

public Boolean isPB3()
Param Boolean 3


setPB3

public SendControlMessage setPB3(Boolean PB3)
Param Boolean 3


toString

public String toString()
Overrides:
toString in class CommandMessage

toHtmlString

public String toHtmlString()

toMessage

public String toMessage()


Copyright © 2015 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.