You are here

public function Queue::enqueueJobs in Advanced Queue 8

Enqueues the given jobs.

Each job will be modified with the assigned queue ID, job ID, and relevant timestamps.

Parameters

\Drupal\advancedqueue\Job[] $jobs: The jobs.

int $delay: The time, in seconds, after which the jobs will become available to consumers. Defaults to 0, indicating no delay.

Overrides QueueInterface::enqueueJobs

File

src/Entity/Queue.php, line 129

Class

Queue
Defines the queue entity class.

Namespace

Drupal\advancedqueue\Entity

Code

public function enqueueJobs(array $jobs, $delay = 0) {
  return $this
    ->getBackend()
    ->enqueueJobs($jobs, $delay);
}