Package VASSAL.chat

Class SimpleRoom

java.lang.Object
VASSAL.chat.SimpleRoom
All Implemented Interfaces:
Room
Direct Known Subclasses:
NodeRoom

public class SimpleRoom extends Object implements Room
A simple Room bean
  • Constructor Details

    • SimpleRoom

      public SimpleRoom()
    • SimpleRoom

      public SimpleRoom(String name)
    • SimpleRoom

      public SimpleRoom(String name, Player[] players)
    • SimpleRoom

      public SimpleRoom(Room copy)
  • Method Details

    • getName

      public String getName()
      Description copied from interface: Room
      The display name of this room
      Specified by:
      getName in interface Room
    • setName

      public void setName(String name)
    • setPlayers

      public void setPlayers(Player[] players)
    • addPlayer

      public void addPlayer(Player p)
      Description copied from interface: Room
      Add a player to this room
      Specified by:
      addPlayer in interface Room
    • getPlayer

      public Player getPlayer(String id)
    • removePlayer

      public void removePlayer(Player p)
      Description copied from interface: Room
      Remove a player from this room
      Specified by:
      removePlayer in interface Room
    • contains

      public boolean contains(Player p)
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • numPlayers

      public int numPlayers()
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • getPlayers

      @Deprecated(since="2020-08-06", forRemoval=true) public Iterator<Player> getPlayers()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Use getPlayerList() instead.
    • getPlayerList

      public List<Player> getPlayerList()
      Description copied from interface: Room
      Return an (unmodifiable) list of players
      Specified by:
      getPlayerList in interface Room