public function UltimateCronLogEntry::getDuration in Ultimate Cron 7.2
Get duration.
1 call to UltimateCronLogEntry::getDuration()
- UltimateCronLogEntry::formatDuration in ./
ultimate_cron.plugin.inc - Format duration.
File
- ./
ultimate_cron.plugin.inc, line 1525 - Plugin framework for Ultimate Cron.
Class
- UltimateCronLogEntry
- Abstract class for Ultimate Cron log entries.
Code
public function getDuration() {
$duration = 0;
if ($this->start_time && $this->end_time) {
$duration = (int) ($this->end_time - $this->start_time);
}
elseif ($this->start_time) {
$duration = (int) (microtime(TRUE) - $this->start_time);
}
return $duration;
}