ProfilerPro::start() method

Start tracking an event

Returns the event array to be used for stop tracking.

Example

$event = $profiler->start('my-event'); 
// execute some other code
$profiler->stop($event);

Usage

// basic usage
$array = $profiler->start(string $name);

// usage with all arguments
$array = $profiler->start(string $name, $source = null, array $data = []);

Arguments

NameType(s)Description
$namestring

Name of your event

$source (optional)Wire object string null

Optional source of event (omit for MyPHP)

$data (optional)array

Additional data, currently not used

Return value

array null

Event to be used for stop call

See Also


$profiler methods and properties

API reference based on ProcessWire core version 3.0.253