public function StopwatchEvent::getTotalTime

Gets the total time of all periods.

Return value

integer The time (in milliseconds)

File

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

Class

StopwatchEvent
Represents an Event managed by Stopwatch.

Namespace

Symfony\Component\HttpKernel\Debug

Code

public function getTotalTime() {
  $total = 0;
  foreach ($this->periods as $period) {
    $total += $period[1] - $period[0];
  }
  return $this
    ->formatTime($total);
}