Uses of Class
java.lang.NumberFormatException
| Package | Description |
|---|---|
| java.awt |
Contains all of the classes for creating user interfaces and for painting
graphics and images.
|
| java.lang |
Provides classes that are fundamental to the design of the Java
programming language.
|
-
Uses of NumberFormatException in java.awt
Methods in java.awt that throw NumberFormatException Modifier and Type Method Description static ColorColor. decode(String nm)Converts aStringto an integer and returns the specified opaqueColor. -
Uses of NumberFormatException in java.lang
Methods in java.lang that throw NumberFormatException Modifier and Type Method Description static ByteByte. decode(String nm)Decodes aStringinto aByte.static IntegerInteger. decode(String nm)Decodes aStringinto anInteger.static LongLong. decode(String nm)Decodes aStringinto aLong.static ShortShort. decode(String nm)Decodes aStringinto aShort.booleanPackage. isCompatibleWith(String desired)Compare this package's specification version with a desired version.static byteByte. parseByte(String s)Parses the string argument as a signed decimalbyte.static byteByte. parseByte(String s, int radix)Parses the string argument as a signedbytein the radix specified by the second argument.static doubleDouble. parseDouble(String s)Returns a newdoubleinitialized to the value represented by the specifiedString, as performed by thevalueOfmethod of classDouble.static floatFloat. parseFloat(String s)Returns a newfloatinitialized to the value represented by the specifiedString, as performed by thevalueOfmethod of classFloat.static intInteger. parseInt(CharSequence s, int beginIndex, int endIndex, int radix)Parses theCharSequenceargument as a signedintin the specifiedradix, beginning at the specifiedbeginIndexand extending toendIndex - 1.static intInteger. parseInt(String s)Parses the string argument as a signed decimal integer.static intInteger. parseInt(String s, int radix)Parses the string argument as a signed integer in the radix specified by the second argument.static longLong. parseLong(CharSequence s, int beginIndex, int endIndex, int radix)Parses theCharSequenceargument as a signedlongin the specifiedradix, beginning at the specifiedbeginIndexand extending toendIndex - 1.static longLong. parseLong(String s)Parses the string argument as a signed decimallong.static longLong. parseLong(String s, int radix)Parses the string argument as a signedlongin the radix specified by the second argument.static shortShort. parseShort(String s)Parses the string argument as a signed decimalshort.static shortShort. parseShort(String s, int radix)Parses the string argument as a signedshortin the radix specified by the second argument.static intInteger. parseUnsignedInt(CharSequence s, int beginIndex, int endIndex, int radix)Parses theCharSequenceargument as an unsignedintin the specifiedradix, beginning at the specifiedbeginIndexand extending toendIndex - 1.static intInteger. parseUnsignedInt(String s)Parses the string argument as an unsigned decimal integer.static intInteger. parseUnsignedInt(String s, int radix)Parses the string argument as an unsigned integer in the radix specified by the second argument.static longLong. parseUnsignedLong(CharSequence s, int beginIndex, int endIndex, int radix)Parses theCharSequenceargument as an unsignedlongin the specifiedradix, beginning at the specifiedbeginIndexand extending toendIndex - 1.static longLong. parseUnsignedLong(String s)Parses the string argument as an unsigned decimallong.static longLong. parseUnsignedLong(String s, int radix)Parses the string argument as an unsignedlongin the radix specified by the second argument.static ByteByte. valueOf(String s)Returns aByteobject holding the value given by the specifiedString.static ByteByte. valueOf(String s, int radix)Returns aByteobject holding the value extracted from the specifiedStringwhen parsed with the radix given by the second argument.static DoubleDouble. valueOf(String s)Returns aDoubleobject holding thedoublevalue represented by the argument strings.static FloatFloat. valueOf(String s)Returns aFloatobject holding thefloatvalue represented by the argument strings.static IntegerInteger. valueOf(String s)Returns anIntegerobject holding the value of the specifiedString.static IntegerInteger. valueOf(String s, int radix)Returns anIntegerobject holding the value extracted from the specifiedStringwhen parsed with the radix given by the second argument.static LongLong. valueOf(String s)Returns aLongobject holding the value of the specifiedString.static LongLong. valueOf(String s, int radix)Returns aLongobject holding the value extracted from the specifiedStringwhen parsed with the radix given by the second argument.static ShortShort. valueOf(String s)Returns aShortobject holding the value given by the specifiedString.static ShortShort. valueOf(String s, int radix)Returns aShortobject holding the value extracted from the specifiedStringwhen parsed with the radix given by the second argument.Constructors in java.lang that throw NumberFormatException Constructor Description Byte(String s)Deprecated.It is rarely appropriate to use this constructor.Double(String s)Deprecated.It is rarely appropriate to use this constructor.Float(String s)Deprecated.It is rarely appropriate to use this constructor.Integer(String s)Deprecated.It is rarely appropriate to use this constructor.Long(String s)Deprecated.It is rarely appropriate to use this constructor.Short(String s)Deprecated.It is rarely appropriate to use this constructor.