public class TypeUtilities
extends java.lang.Object
Constructor and Description |
---|
TypeUtilities() |
Modifier and Type | Method and Description |
---|---|
static boolean |
equals(java.lang.Object o1,
java.lang.Object o2)
This implementation of equals is useful in the following ways:
Null-safe: null==null
Number-safe: (new Long(0))==(new Integer(0)) and Boolean.TRUE == new Integer(1)
Other than that, it delegates to the argument's .equals functions.
|
static boolean |
isFractional(java.lang.Class<?> cls) |
static boolean |
isNullOrEmpty(java.lang.String s) |
static boolean |
isNumber(java.lang.Class<?> cls)
Returns true if the class is boolean or is a proper number.
|
public static boolean isNullOrEmpty(java.lang.String s)
public static boolean equals(java.lang.Object o1, java.lang.Object o2)
public static boolean isNumber(java.lang.Class<?> cls)
public static boolean isFractional(java.lang.Class<?> cls)