public static boolean isPrimitiveOrObject(final String type) {
    return "byte".equalsIgnoreCase(type) || "short".equalsIgnoreCase(type)
        || "int".equalsIgnoreCase(type) || "long".equalsIgnoreCase(type)
        || "float".equalsIgnoreCase(type) || "double".equalsIgnoreCase(type)
        || "boolean".equalsIgnoreCase(type) || "string".equalsIgnoreCase(type);
  }
The NumberUtils class is a utility class for working with numbers.
<p>

@see java.lang.Number
@since GemFire 8.0
geode-web-api/src/main/java/org/apache/geode/rest/internal/web/util/NumberUtils.java