oracle.bali.share.util
Class IntegerUtils
java.lang.Object
|
+--oracle.bali.share.util.IntegerUtils
- public final class IntegerUtils
- extends java.lang.Object
Class containing various integer utilities. It caches commonly used Integer objects and String representations of Integers to avoid expensive object creations.
IntegerUtils is used throughout most Bali projects, and clients are also encouraged to use it for increased performance.
- Since:
- Inspector 0.2
Method Summary |
static java.lang.Integer |
getInteger(int intValue)
|
static java.lang.String |
getString(int intValue)
|
static java.lang.String |
getString(java.lang.Integer intObject)
|
static java.lang.String |
getString(long longValue)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
getInteger
public static java.lang.Integer getInteger(int intValue)
-
- Returns:
- an Integer object for the specified integer, possibly creating a new Integer object if a cached one does not exist.
getString
public static java.lang.String getString(int intValue)
-
- Returns:
- a String value corresponding to the specified integer, possibly creating a new String object if a cached one does not exist.
getString
public static java.lang.String getString(long longValue)
-
- Returns:
- a String value corresponding to the specified long, possibly creating a new String object if a cached one does not exist.
getString
public static java.lang.String getString(java.lang.Integer intObject)
-
- Returns:
- a String value corresponding to the specified Integer, possibly creating a new String object if a cached one does not exist.