public static Class<?> toRawType(final Type type) {
		if (type instanceof Class<?> cls) {
			return cls;
		} else if (type instanceof ParameterizedType pt &&
			pt.getRawType() instanceof Class<?> cls)
		{
			return cls;
		} else {
			return null;
		}
	}
Return the raw type of the given Java type, given its context. If the
type is a {@link ParameterizedType}, its raw type is returned.

@param type the type to resolve
@return the resolved {@link Class} object or {@code null} if
        the type could not be resolved
jenetics.incubator/src/main/java/io/jenetics/incubator/beans/internal/Reflect.java