You are here

public function SchedulerEvent::setNode in Scheduler 2.x

Sets the node object (same as the entity object).

This method is retained for backwards compatibility because implementations of the event subscriber functions may be using $event->setNode().

Parameters

\Drupal\Core\Entity\EntityInterface $entity: The entity object that caused the event to fire.

File

src/Event/SchedulerEvent.php, line 54

Class

SchedulerEvent
Wraps a scheduler event for event listeners.

Namespace

Drupal\scheduler\Event

Code

public function setNode(EntityInterface $entity) {
  $this->entity = $entity;
}