Gets the total time of all periods.
integer The time (in milliseconds)
public function getTotalTime() { $total = 0; foreach ($this->periods as $period) { $total += $period[1] - $period[0]; } return $this ->formatTime($total); }