Java tutorial
//package com.java2s; import java.lang.reflect.Type; public class Main { static void checkNotPrimitive(Type paramType) { if (((paramType instanceof Class)) && (((Class) paramType).isPrimitive())) throw new IllegalArgumentException(); } }