Inherits ApiClass, and ScriptingObject.
Public Member Functions | |
void | assertEqual (var v1, var v2) |
void | assertIsDefined (var value) |
void | assertIsObjectOrArray (var value) |
void | assertLegalNumber (var value) |
void | assertTrue (var condition) |
void | clear () |
void | print (var debug) |
void | start () |
void | stop () |
A set of handy function to debug the script.
void assertEqual | ( | var | v1, |
var | v2 | ||
) |
Throws an error message if the values are not equal.
void assertIsDefined | ( | var | value | ) |
Throws an error message if the value is undefined.
void assertIsObjectOrArray | ( | var | value | ) |
Throws an error message if the value is not an object or array.
void assertLegalNumber | ( | var | value | ) |
Throws an error message if the value is not a legal number (eg. string or array or infinity or NaN).
void assertTrue | ( | var | condition | ) |
Throws an error message if the condition is not true.
void clear | ( | ) |
Clears the console.
void print | ( | var | debug | ) |
Prints a message to the console.
void start | ( | ) |
Starts the benchmark. You can give it a name that will be displayed with the result if desired.
void stop | ( | ) |
Stops the benchmark and prints the result.