RIATest 2 Documentation Copyright © RIATest.com

Number Object

Number represents the double-precision 64-bit format IEEE 754 values.

Methods

MethodDescription

Number

new Number([value])
Create new Number value

toExponential

toExponential(fractionDigits)
Return a string containing the number represented in exponential notation with one digit before the significand's decimal point and fractionDigits digits after the significand's decimal point. If fractionDigits is undefined, include as many significand digits as necessary to uniquely specify the number (just like in ToString except that in this case the number is always output in exponential notation).

toFixed

toFixed(fractionDigits)
Return a string containing the number represented in fixed-point notation with fractionDigits digits after the decimal point. If fractionDigits is undefined, 0 is assumed.

toString

toString(argument)
Convert number to string representation. Optional radix argument from 2 to 32 can be supplied if the number is integer. If radix is ommited radix 10 is used. For fractional numbers and numbers less than -2^31 or greater than 2^31-1 only radix 10 is allowed.