static isFinite(value
:
Object)
:
boolean
Determines whether the passed value is a finite number.
static isInteger(value
:
Object)
:
boolean
Determines whether the passed value is an integer number.
static isNaN(value
:
Object)
:
boolean
Determines whether the passed value is NaN
.
static isSafeInteger(value
:
Object)
:
boolean
Determines whether the passed value is a safe integer number.
toExponential(digits
:
Number)
:
String
Converts this Number to a String using exponential notation with the specified number of digits after the decimal place.
toFixed()
:
String
Converts a Number to a String that contains a no fractional part.
toFixed(digits
:
Number)
:
String
Converts a Number to a String that contains a specified number of digits after the decimal place.
toLocaleString()
:
String
Converts this Number to a String using local number formatting conventions.
toPrecision(precision
:
Number)
:
String
Converts a Number to a String using the specified number of significant digits.
toString(radix
:
Number)
:
String
Converts the number into a string using the specified radix (base).
isFinite
static
isFinite(value
:
Object)
:
boolean
Determines whether the passed value is a finite number.
API Versioned:
From version 21.2.
Parameters:
value
-
The value to check.
Returns:
true
if the passed value is a finite number, else false
.
isInteger
static
isInteger(value
:
Object)
:
boolean
Determines whether the passed value is an integer number.
API Versioned:
From version 21.2.
Parameters:
value
-
The value to check.
Returns:
true
if the passed value is a finite integer number, else false
.
isNaN
static
isNaN(value
:
Object)
:
boolean
Determines whether the passed value is NaN
. Unlike the global function, the passed parameter is not converted to number before doing the check.
API Versioned:
From version 21.2.
Parameters:
value
-
The value to check.
Returns:
true
if the passed value is the NaN
number value, else false
.
isSafeInteger
static
isSafeInteger(value
:
Object)
:
boolean
Determines whether the passed value is a safe integer number.
API Versioned:
From version 21.2.
Parameters:
value
-
The value to check.
Returns:
true
if the passed value is a safe integer number, else false
.
parseFloat
Parses a String into an float Number.
API Versioned:
From version 21.2.
Parameters:
s
-
the String to parse.
Returns:
Returns the float as a Number.
parseInt
Parses a String into an integer Number.
This function is a short form for the call to
parseInt(String, Number) with automatic determination of the radix.
If the string starts with "0x" or "0X" then the radix is 16. In all other cases the radix is 10.
API Versioned:
From version 21.2.
Parameters:
s
-
the String to parse.
Returns:
Returns the integer as a Number.
parseInt
Parses a String into an integer Number using the
specified radix.
API Versioned:
From version 21.2.
Parameters:
s
-
the String to parse.
radix
-
the radix to use.
Returns:
Returns the integer as a Number.
toExponential
Converts this Number to a String using exponential notation.
Returns:
a String using exponential notation.
toExponential
Converts this Number to a String using exponential notation with
the specified number of digits after the decimal place.
Parameters:
digits
-
the number of digits after the decimal place.
Returns:
a String using exponential notation with the specified number of digits after the decimal place.
toFixed
Converts a Number to a String that contains a no fractional part.
Returns:
a String representation of the number
toFixed
Converts a Number to a String that contains a specified number
of digits after the decimal place.
Parameters:
digits
-
the number of digits after the decimal place.
Returns:
a String that contains a specified number of digits after the decimal place.
toLocaleString
Converts this Number to a String using local number formatting conventions.
The current implementation actually only returns the same as
toString().
Returns:
a String using local number formatting conventions.
toPrecision
Converts a Number to a String using the specified number
of significant digits. Uses exponential or fixed point
notation depending on the size of the number and the number of
significant digits specified.
Parameters:
precision
-
the precision to use when converting the Number to a String.
Returns:
a String using the specified number of significant digits.
toString
A String representation of this Number.
Returns:
a String representation of this Number.
toString
Converts the number into a string using the specified radix (base).
Parameters:
radix
-
the radix to use.
Returns:
a String representation of this Number.