public static boolean isPrimitiveOrWrapper(Class<?> klass) {
    return klass.isAssignableFrom(Byte.class) || klass.isAssignableFrom(byte.class)
        || klass.isAssignableFrom(Short.class) || klass.isAssignableFrom(short.class)
        || klass.isAssignableFrom(Integer.class) || klass.isAssignableFrom(int.class)
        || klass.isAssignableFrom(Long.class) || klass.isAssignableFrom(long.class)
        || klass.isAssignableFrom(Float.class) || klass.isAssignableFrom(float.class)
        || klass.isAssignableFrom(Double.class) || klass.isAssignableFrom(double.class)
        || klass.isAssignableFrom(Boolean.class) || klass.isAssignableFrom(boolean.class)
        || klass.isAssignableFrom(Character.class) || klass.isAssignableFrom(char.class)
        || klass.isAssignableFrom(String.class);
  }
This class contains utility methods for JSON (http://www.json.org/) which is used by classes used
for the Command Line Interface (CLI).

@since GemFire 7.0
geode-core/src/main/java/org/apache/geode/management/internal/util/JsonUtil.java