org.datamanager.passiveentityvalue
Interface NumericEntityValue
- All Superinterfaces:
- Comparable, EntityValue, PassiveEntityValue, Serializable
- All Known Implementing Classes:
- NumberEntityValue
- public interface NumericEntityValue
- extends PassiveEntityValue, Comparable
NumericEntityValue is an interface that provides for a common working
all numerical types, that is rational numbers, integers, and whatever
else we can come up with.
isInRange
public boolean isInRange(NumericEntityValue low,
NumericEntityValue high)
isInRange
public boolean isInRange(double low,
double high)
isGreaterThan
public boolean isGreaterThan(NumericEntityValue low)
isGreaterThan
public boolean isGreaterThan(double low)
isGreaterThanOrEqualTo
public boolean isGreaterThanOrEqualTo(NumericEntityValue low)
isGreaterThanOrEqualTo
public boolean isGreaterThanOrEqualTo(double low)
isLesserThan
public boolean isLesserThan(NumericEntityValue high)
isLesserThan
public boolean isLesserThan(double high)
isLesserThanOrEqualTo
public boolean isLesserThanOrEqualTo(NumericEntityValue high)
isLesserThanOrEqualTo
public boolean isLesserThanOrEqualTo(double high)
equals
public boolean equals(NumericEntityValue n)
equals
public boolean equals(double d)
equals
public boolean equals(Object o)
- Specified by:
equals
in interface PassiveEntityValue
- Overrides:
equals
in class Object
compareTo
public int compareTo(NumericEntityValue n)
compareTo
public int compareTo(Object o)
- Specified by:
compareTo
in interface Comparable
getNearestInt
public int getNearestInt()
getFloor
public int getFloor()
getCeiling
public int getCeiling()
getNearestDouble
public double getNearestDouble()
toString
public String toString()
- Overrides:
toString
in class Object
add
public void add(NumericEntityValue addend)
add
public void add(double addend)
subtract
public void subtract(NumericEntityValue subtrahend)
subtract
public void subtract(double subtrahend)
multiplyBy
public void multiplyBy(NumericEntityValue multiplier)
multiplyBy
public void multiplyBy(double multiplier)
divideBy
public void divideBy(NumericEntityValue divisor)
divideBy
public void divideBy(double divisor)
See the Helium Website