T
- the generic typepublic class AttributeModifier<T extends java.lang.Number> extends java.lang.Object implements java.lang.Comparable<AttributeModifier<T>>
Constructor and Description |
---|
AttributeModifier(Modification mod,
double modifyValue)
Initializes a new instance of the
AttributeModifier class. |
Modifier and Type | Method and Description |
---|---|
int |
compareTo(AttributeModifier<T> otherModifier) |
boolean |
equals(java.lang.Object obj) |
Modification |
getModification()
Gets the modification type applied by this modifier.
|
double |
getModifyValue()
Gets the value that is used to modify an attribute.
|
int |
hashCode() |
boolean |
isActive() |
T |
modify(T modvalue) |
void |
setActive(boolean active) |
void |
setModifyValue(double value) |
public AttributeModifier(Modification mod, double modifyValue)
AttributeModifier
class.mod
- The modification type.modifyValue
- The modification value to be applied by this instance.public int compareTo(AttributeModifier<T> otherModifier)
compareTo
in interface java.lang.Comparable<AttributeModifier<T extends java.lang.Number>>
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public Modification getModification()
public double getModifyValue()
public boolean isActive()
public void setModifyValue(double value)
public void setActive(boolean active)