Package java.lang
Class Integer
static Integer valueOf(String s)
Throws:
static Integer valueOf(String s, int radix)
Throws:
_INSERT_METHOD_SIGNATURE_HERE_
Description:
valueOf(String s) method:
Returns a new Integer object initialized to the value of the specified String. The argument is interpreted as representing a signed decimal integer, exactly as if the argument were given to the parseInt(java.lang.String) method. The result is an Integer object that represents the integer value specified by the string.
valueOf(String s, int radix) method:
Returns a new Integer object initialized to the value of the specified String. The first argument is interpreted as representing a signed integer in the radix specified by the second argument, exactly as if the arguments were given to the parseInt(java.lang.String, int) method. The result is an Integer object that represents the integer value specified by the string.
Example
Integer in = Integer.valueOf("9");
The valueOf() method returns the Integer representation of the decimal value 10.