Profiler
class Profiler
Utility class to assist in the process of benchmarking the execution of sections of code to understand where time is being spent.
Properties
Methods
__construct(string $prefix = '')
Constructor
static Profiler
getInstance(string $prefix = '')
Returns the global Profiler object, only creating it if it doesn't already exist.
string
mark(string $label)
Output a time mark
array
getMarks()
Get all profiler marks.
array
getBuffer()
Get all profiler mark buffers.
$this
setStart(float $startTime = 0.0, int $startMem = 0)
Sets the start time.
Details
static Profiler
getInstance(string $prefix = '')
Since: 1.7.0
Returns the global Profiler object, only creating it if it doesn't already exist.
array
getMarks()
Since: 1.7.0
Get all profiler marks.
Returns an array of all marks created since the Profiler object was instantiated. Marks are objects as per JProfiler::mark().