Package net.sf.freecol.common.model
Enum Player.PlayerType
- java.lang.Object
-
- java.lang.Enum<Player.PlayerType>
-
- net.sf.freecol.common.model.Player.PlayerType
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<Player.PlayerType>
- Enclosing class:
- Player
public static enum Player.PlayerType extends java.lang.Enum<Player.PlayerType>
Types of players.
-
-
Constructor Summary
Constructors Modifier Constructor Description private
PlayerType()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Player.PlayerType
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static Player.PlayerType[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
NATIVE
public static final Player.PlayerType NATIVE
-
COLONIAL
public static final Player.PlayerType COLONIAL
-
REBEL
public static final Player.PlayerType REBEL
-
INDEPENDENT
public static final Player.PlayerType INDEPENDENT
-
ROYAL
public static final Player.PlayerType ROYAL
-
UNDEAD
public static final Player.PlayerType UNDEAD
-
RETIRED
public static final Player.PlayerType RETIRED
-
-
Method Detail
-
values
public static Player.PlayerType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (Player.PlayerType c : Player.PlayerType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Player.PlayerType valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
-