public void register(Type<?> type) {
        typeByClass.put(type.getReturnedClass(), type);
        Class<?> primitive = PrimitiveUtils.unwrap(type.getReturnedClass());
        if (primitive != null) {
            typeByClass.put(primitive, type);
        }
        // Clear previous resolved types, so they won't impact future lookups
        resolvedTypesByClass.clear();
    }
{@code JavaTypeMapping} provides a mapping from Class to Type instances

@author tiwe
querydsl-sql/src/main/java/com/querydsl/sql/JavaTypeMapping.java