PlayerList.java :  » Game » Arianne-RPG-0.83 » games » stendhal » client » Java Open Source

Java Open Source » Game » Arianne RPG 0.83 
Arianne RPG 0.83 » games » stendhal » client » PlayerList.java
package games.stendhal.client;

import java.util.HashSet;
import java.util.Set;

public class PlayerList {
  
  private Set<String> namesList = new HashSet<String>();

  public Set<String> getNamesList() {
    return namesList;
  }
  
  public void removePlayer(String player) {
    namesList.remove(player);
  }
  
  public void addPlayer(String player) {
    namesList.add(player);
  }

  public boolean contains(String player) {
    return namesList.contains(player);
  }
}
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.