List of utility methods to do Class to Primitive
Class> | getPrimitiveClass(String name) get Primitive Class if (name.length() <= PRIMITIVE_CLASS_NAME_MAX_LENGTH) { int index = Arrays.binarySearch(PRIMITIVE_NAMES, name); if (index >= 0) { return PRIMITIVE_CLASSES[index]; return null; |
Object | getPrimitiveDftValue(Class> clazz) get Primitive Dft Value return primitiveTypeDftValueMap.get(clazz);
|
Class> | getPrimitiveTypeByWrapper(Class> clazz) get Primitive Type By Wrapper return wrapperPrimitiveTypeMap.get(clazz);
|
Class> | getPrimitiveWrapper(Class> c) If the specified class is a primitive (e.g. return pmap1.get(c);
|
Class> | getWrapper(String primitiveClassName) get Wrapper return primitiveTypeMap.get(primitiveClassName);
|
Class> | getWrapperTypeByPrimitive(Class> clazz) get Wrapper Type By Primitive return primitiveWrapperTypeMap.get(clazz);
|
Class | primitiveToWrapper(Class cls) Converts the specified primitive Class object to its corresponding wrapper Class object. Class convertedClass = cls; if (cls != null && cls.isPrimitive()) convertedClass = (Class) primitiveWrapperMap.get(cls); return convertedClass; |
Class | primitiveToWrapper(Class in) convert the input class to a wrapper class returns in if the argument is not primitive if (!in.isPrimitive()) return (in); if (gPrimitiveClassToWrapper == null) buildWrapperMapping(); return ((Class) gPrimitiveClassToWrapper.get(in)); |
Class> | primitiveToWrapper(final Class> p) Returns referenced wrapper for primitive type. return PRIMITIVES_TO_WRAPPERS.get(p);
|
Class | toClass(String primitiveName) Convert a primitive name (int, byte etc.) to a class or null if the name is not a primitive. return (Class) PRIMITIVE_NAME_MAP.get(primitiveName);
|