protected function Mailer::startTimer in Simplenews 3.x
Same name and namespace in other branches
- 8.2 src/Mail/Mailer.php \Drupal\simplenews\Mail\Mailer::startTimer()
- 8 src/Mail/Mailer.php \Drupal\simplenews\Mail\Mailer::startTimer()
Starts the execution timer.
1 call to Mailer::startTimer()
- Mailer::sendSpool in src/
Mail/ Mailer.php - Send simplenews newsletters from the spool.
File
- src/
Mail/ Mailer.php, line 483
Class
- Mailer
- Default Mailer.
Namespace
Drupal\simplenews\MailCode
protected function startTimer() {
// Windows systems don't implement getrusage(). There is no alternative.
if (!function_exists('getrusage')) {
return;
}
$usage = getrusage();
$this->startTime = (double) ($usage['ru_stime.tv_sec'] . '.' . $usage['ru_stime.tv_usec']) + (double) ($usage['ru_utime.tv_sec'] . '.' . $usage['ru_utime.tv_usec']);
}