public static boolean isIntegral(Type type){
  if (type == null) {
    return false;
  }
switch (type.getKind()) {
case BYTE:
case SHORT:
case INT:
case LONG:
    return true;
default :
  return false;
}
}

public static boolean isIntegral ( Type type ) { if ( type == null ) { return false ; } switch ( type . getKind ( ) ) { case BYTE : case SHORT : case INT : case LONG : return true ; default : return false ; } }
returns true is the type is an integral numeric value .
