ch.sahits.game.openpatrician.model.weapon
Enum EWeapon
java.lang.Object
java.lang.Enum<EWeapon>
ch.sahits.game.openpatrician.model.weapon.EWeapon
- All Implemented Interfaces:
- IAmountable, IWeapon, Serializable, Comparable<EWeapon>
public enum EWeapon
- extends Enum<EWeapon>
- implements IWeapon
Enumeration defining all weapons
- Author:
- Andi Hotz, (c) Sahits GmbH, 2011
Created on Dec 23, 2011
|
Method Summary |
String |
getLocalDisplayName()
Retrieve the localized display name for id. |
static EWeapon |
valueOf(String name)
Returns the enum constant of this type with the specified name. |
static EWeapon[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared. |
| Methods inherited from interface ch.sahits.game.openpatrician.model.weapon.IWeapon |
name |
SWORD
public static final EWeapon SWORD
BOW
public static final EWeapon BOW
CROSSBOW
public static final EWeapon CROSSBOW
MUSKET
public static final EWeapon MUSKET
BALLISTA_SMALL
public static final EWeapon BALLISTA_SMALL
TREBUCHET_SMALL
public static final EWeapon TREBUCHET_SMALL
BALLISTA_BIG
public static final EWeapon BALLISTA_BIG
TREBUCHET_BIG
public static final EWeapon TREBUCHET_BIG
BOMBARD
public static final EWeapon BOMBARD
CANNON
public static final EWeapon CANNON
HAND_WEAPON
public static final EWeapon HAND_WEAPON
locale
private final Locale locale
values
public static EWeapon[] 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 (EWeapon c : EWeapon.values())
System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in
the order they are declared
valueOf
public static EWeapon valueOf(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:
IllegalArgumentException - if this enum type has no constant
with the specified name
NullPointerException - if the argument is null
getLocalDisplayName
public String getLocalDisplayName()
- Retrieve the localized display name for
id.
- Specified by:
getLocalDisplayName in interface IWeapon
- Parameters:
id -
- Returns:
Copyright © 2011-2012 Sahits GmbH. All Rights Reserved.