the compact javascript framework
in partnership with mediatemple
Contains the Number prototypes.
MIT-style license.
Number.js | Contains the Number prototypes. |
Number | A collection of The Number Object prototype methods. |
Properties | |
toInt | Returns this number; useful because toInt must work on both Strings and Numbers. |
toFloat | Returns this number as a float; useful because toFloat must work on both Strings and Numbers. |
limit | Limits the number. |
round | Returns the number rounded to specified precision. |
times | Executes a passed in function the specified number of times |
A collection of The Number Object prototype methods.
Properties | |
toInt | Returns this number; useful because toInt must work on both Strings and Numbers. |
toFloat | Returns this number as a float; useful because toFloat must work on both Strings and Numbers. |
limit | Limits the number. |
round | Returns the number rounded to specified precision. |
times | Executes a passed in function the specified number of times |
Returns this number as a float; useful because toFloat must work on both Strings and Numbers.
Limits the number.
min | number, minimum value |
max | number, maximum value |
the number in the given limits.
(12).limit(2, 6.5) // returns 6.5 (-4).limit(2, 6.5) // returns 2 (4.3).limit(2, 6.5) // returns 4.3
Documentation by Aaron Newton & Mootools Developers, generated by NaturalDocs and GeSHi