Klasse MapMessage

java.lang.Object
com.jme3.network.AbstractMessage
pp.battleship.message.client.ClientMessage
pp.battleship.message.client.MapMessage
Alle implementierten Schnittstellen:
com.jme3.network.Message

public class MapMessage extends ClientMessage
A message sent by the client containing the positions of the ships on the player's map.
  • Konstruktordetails

    • MapMessage

      public MapMessage(List<Battleship> ships)
      Constructs a MapMessage with the specified list of ships.
      Parameter:
      ships - the list of ships placed on the player's map
  • Methodendetails

    • getShips

      public List<Battleship> getShips()
      Returns the list of ships on the player's map.
      Gibt zurück:
      the list of ships
    • toString

      public String toString()
      Returns a string representation of the MapMessage.
      Setzt außer Kraft:
      toString in Klasse Object
      Gibt zurück:
      a string representation of the MapMessage
    • accept

      public void accept(ClientInterpreter interpreter, int from)
      Accepts a visitor to process this message.
      Angegeben von:
      accept in Klasse ClientMessage
      Parameter:
      interpreter - the visitor to process this message
      from - the connection ID from which the message was received