Java Reflection Primitive getPrimitiveType(Class clazz)

Here you can find the source of getPrimitiveType(Class clazz)

Description

get Primitive Type

License

Open Source License

Declaration

private static Class<?> getPrimitiveType(Class<?> clazz) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import java.util.HashMap;
import java.util.Map;

public class Main {
    private static final Map<Class<?>, Class<?>> CORRESPONDING_TYPES = new HashMap<>();

    private static Class<?> getPrimitiveType(Class<?> clazz) {
        return CORRESPONDING_TYPES.containsKey(clazz) ? CORRESPONDING_TYPES.get(clazz) : clazz;
    }//from w w  w.  ja  v  a  2 s  . c  om
}

Related

  1. getPrimitiveClass(String primitiveName)
  2. getPrimitiveClassIfWrapper(Class clazz)
  3. getPrimitiveDefault(Class primitiveClazz)
  4. getPrimitivePromotionCost(final Class srcClass, final Class destClass)
  5. getPrimitiveSize(Class type)
  6. getPrimitiveType(String javaClassName)
  7. getPrimitiveWrapper(Class primitiveType)
  8. getRank(Class aNumberClass)
  9. getWrapper(Class clazz)