从java api上可以看到。两者的区别。
static int | parseInt(String s, int radix) Parses the string argument as a signed integer in the radix specified by the second argument. |
static Integer | valueOf(String s) Returns an Integer object holding the value of the specified String . |
即,valueof输出的是一个Integer对象。而parseInt输出的是一个int数。