You are here

public function WebformScheduledEmailManagerInterface::cron in Webform 6.x

Same name and namespace in other branches
  1. 8.5 modules/webform_scheduled_email/src/WebformScheduledEmailManagerInterface.php \Drupal\webform_scheduled_email\WebformScheduledEmailManagerInterface::cron()

Cron task for scheduling and sending emails.

Parameters

\Drupal\Core\Entity\EntityInterface $entity: A webform or webform submission.

string|null $handler_id: A webform handler id.

int $schedule_limit: The maximum number of emails to be scheduled. If set to 0 no emails will be scheduled.

int $send_limit: The maximum number of emails to be sent. If set to 0 no emails will be sent. Defaults to webform.settting->batch.default_batch_email_size.

Return value

array An associative array containing cron task stats. Includes:

1 method overrides WebformScheduledEmailManagerInterface::cron()
WebformScheduledEmailManager::cron in modules/webform_scheduled_email/src/WebformScheduledEmailManager.php
Cron task for scheduling and sending emails.

File

modules/webform_scheduled_email/src/WebformScheduledEmailManagerInterface.php, line 294

Class

WebformScheduledEmailManagerInterface
Provides an interface for managing webform scheduled emails.

Namespace

Drupal\webform_scheduled_email

Code

public function cron(EntityInterface $entity = NULL, $handler_id = NULL, $schedule_limit = 1000, $send_limit = NULL);