Package megamek.common.alphaStrike
Enum Class ASUnitType
- All Implemented Interfaces:
Serializable,Comparable<ASUnitType>,Constable
Represents the AlphaStrike Element Types (ASC, page 91)
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptionstatic ASUnitTypegetUnitType(Entity en) Returns the AlphaStrike element type for the given entity or UNKNOWN if it has no AS equivalent.booleanisAnyOf(ASUnitType type, ASUnitType... furtherTypes) Returns true if this AS Element Type is equal to any of the given Types.booleanbooleanbooleanbooleanbooleanbooleanbooleanisMek()booleanbooleanstatic ASUnitTypeReturns the enum constant of this class with the specified name.static ASUnitType[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
BM
-
IM
-
PM
-
CV
-
SV
-
MS
-
BA
-
CI
-
AF
-
CF
-
SC
-
DS
-
DA
-
JS
-
WS
-
SS
-
UNKNOWN
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified nameNullPointerException- if the argument is null
-
getUnitType
Returns the AlphaStrike element type for the given entity or UNKNOWN if it has no AS equivalent. -
isAnyOf
Returns true if this AS Element Type is equal to any of the given Types. -
isBattleMek
public boolean isBattleMek()- Returns:
- True if this ASUnitType is BattleMek (BM).
-
isProtoMek
public boolean isProtoMek()- Returns:
- True if this ASUnitType is ProtoMek (PM).
-
isLargeAerospace
public boolean isLargeAerospace()- Returns:
- True if this ASUnitType is a Large Aerospace type, i.e. SC, DS, DA, SS, JS, WS.
-
isBattleArmor
public boolean isBattleArmor()- Returns:
- True if this ASUnitType is BattleArmor (BA).
-
isConventionalInfantry
public boolean isConventionalInfantry()- Returns:
- True if this ASUnitType is Conventional Infantry (CI).
-
isMek
public boolean isMek()- Returns:
- True if this ASUnitType is a BattleMek or Industrial Mek type (BM, IM).
-
isInfantry
public boolean isInfantry()- Returns:
- True if this ASUnitType is an Infantry type (BA or CI).
-
isCombatVehicle
public boolean isCombatVehicle()- Returns:
- True if this ASUnitType is Combat Vehicle (CV).
-
isSupportVehicle
public boolean isSupportVehicle()- Returns:
- True if this ASUnitType is Support Vehicle (SV).
-