public class BoxedWrapper
extends java.lang.Object
Constructor and Description |
---|
BoxedWrapper() |
Modifier and Type | Method and Description |
---|---|
static java.lang.Class<?> |
getBoxedFromPrimitiveType(java.lang.Class<?> primitiveType)
Get the wrapped counter part from a primitive type.
|
static boolean |
hasBoxedCounterPart(java.lang.Class<?> type)
Returns
true if type has a primitive
counter-part. |
public static java.lang.Class<?> getBoxedFromPrimitiveType(java.lang.Class<?> primitiveType)
getBoxedFromPrimitiveType(int.class)
will return
Integer.class
.
primitiveType
- The primitive type to convert to its wrapper counter part.null
if the class did
not have a boxed counter part.public static boolean hasBoxedCounterPart(java.lang.Class<?> type)
true
if type
has a primitive
counter-part. E.g. if type
if Integer
then this
method will return true
.type
- The type to check whether or not it has a primitive
counter-part.true
if this type has a primitive counter-part.