|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectspellcast.damage.DamageType
public class DamageType
The type for damage being dealt. DamageType uses a Flyweight pattern and instances are created through the getX() calls.
| Field Summary | |
|---|---|
static DamageType[] |
ALL_DAMAGE_TYPES
List of all the DamageTypes. |
| Constructor Summary | |
|---|---|
protected |
DamageType(java.lang.String type_)
DamageType is not instantied but accessed from the Flyweight factory methods getX(), where X is one of the available damage types. |
| Method Summary | |
|---|---|
boolean |
equals(java.lang.Object o)
A damage type is equal to another damage type if they have the same type. |
static DamageType |
getColdDamageType()
|
static DamageType |
getFireDamageType()
|
static DamageType |
getPhysicalDamageType()
|
java.lang.String |
getType()
|
boolean |
isNull()
|
void |
setNull(boolean isNullable)
Set whether this object is a Nullable. |
void |
setType(java.lang.String type_)
|
java.lang.String |
toString()
The string value of a damage type is it's type. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final DamageType[] ALL_DAMAGE_TYPES
DamageTypes.
| Constructor Detail |
|---|
protected DamageType(java.lang.String type_)
| Method Detail |
|---|
public final void setNull(boolean isNullable)
Nullable.
isNullable - true if this object is a Null instance, false
otherwise.public final boolean isNull()
isNull in interface util.Nullablepublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.String getType()
public void setType(java.lang.String type_)
public static final DamageType getPhysicalDamageType()
public static final DamageType getFireDamageType()
public static final DamageType getColdDamageType()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||