|
Whitebeam Template Reference Documentation
|
System Template
time()
Return time taken to process a page (so far)
Syntax
void = rb.debug.time()
Parameters
The 'time' method takes no parameters
Results
The 'time' method returns no useful information.
Remarks This method returns the number of microseconds that have elapsed since
Whitebeam started processing this page. This information can be invaluable in profiling an application that is performing
badly. A call placed right at the end of a page can tell you how long
the entire page has taken to generate. Wrapping critical sections in calls
will tell you how long that section has taken. Example
var startTime = rb.debug.time();
callBigSlowFunction();
var endTime = rb.debug.time();
rb.debug.write("bigSlowFunction() took ",
(endTime-startTime)," micro-seconds to execute<br>");
|
|
(loadtime : 472ms) |