Package com.scriptbasic.utility
Class NumberUtility
java.lang.Object
com.scriptbasic.utility.NumberUtility
Utility class to compare Number variables, Long or Double.
- Author:
- Peter Verhas date Jul 21, 2012
-
Method Summary
Modifier and TypeMethodDescriptionstatic intCompares the numbers a and b.static booleanisPositive(Number a)
-
Method Details
-
isPositive
-
compare
Compares the numbers a and b.- Parameters:
a- one of the numbersb- the other number- Returns:
- 0 if a == b; 1 if a > b; and -1 if b < a
-