public function Section::startEvent

Starts an event.

Parameters

string $name The event name:

string $category The event category:

Return value

StopwatchEvent The event

File

drupal/core/vendor/symfony/http-kernel/Symfony/Component/HttpKernel/Debug/Stopwatch.php, line 201

Class

Section

Namespace

Symfony\Component\HttpKernel\Debug

Code

public function startEvent($name, $category) {
  if (!isset($this->events[$name])) {
    $this->events[$name] = new StopwatchEvent($this->origin ?: microtime(true) * 1000, $category);
  }
  return $this->events[$name]
    ->start();
}