MCPcopy Create free account
hub / github.com/codenameone/CodenameOne / valueOf

Method valueOf

vm/JavaAPI/src/java/lang/Float.java:251–253  ·  view source on GitHub ↗

Returns the floating point value represented by the specified String. The string s is interpreted as the representation of a floating-point value and a Float object representing that value is created and returned. If s is null, then a NullPointerException is thrown. Leading and trailing whitespace c

(java.lang.String s)

Source from the content-addressed store, hash-verified

249 * , then a NumberFormatException is thrown. Otherwise, it is regarded as representing an exact decimal value in the usual "computerized scientific notation"; this exact decimal value is then conceptually converted to an "infinitely precise" binary value that is then rounded to type float by the usual round-to-nearest rule of IEEE 754 floating-point arithmetic.
250 */
251 public static java.lang.Float valueOf(java.lang.String s) throws java.lang.NumberFormatException{
252 return Float.parseFloat(s);
253 }
254
255
256 /**

Callers 15

decodeValueMethod · 0.95
setMethod · 0.95
parseStopsMethod · 0.95
ResizeConstraintClass · 0.95
parseFloatMethod · 0.95
growXMethod · 0.95
shrinkXMethod · 0.95
shrinkYMethod · 0.95
getPixelUnitFactorMethod · 0.95
growMethod · 0.95
shrinkMethod · 0.95

Calls 1

parseFloatMethod · 0.95

Tested by 4

runTestMethod · 0.76
getPrivateFieldMethod · 0.76
parseResourceFileXmlMethod · 0.76