Elgg  Version master
Enqueue.php
Go to the documentation of this file.
1 <?php
2 
4 
11 class Enqueue {
12 
25  public function __invoke(\Elgg\Event $event) {
26  $object = $event->getObject();
27  if (!$object instanceof \ElggData) {
28  return;
29  }
30 
31  _elgg_services()->notifications->enqueueEvent($event->getName(), $object);
32  }
33 }
A generic class that contains shared code among \ElggExtender, \ElggEntity, and \ElggRelationship.
Definition: ElggData.php:12
Models an event passed to event handlers.
Definition: Event.php:11
Enqueue notification event.
Definition: Enqueue.php:11
__invoke(\Elgg\Event $event)
Queue a notification event for later handling.
Definition: Enqueue.php:25
if($email instanceof \Elgg\Email) $object
Definition: body.php:24
_elgg_services()
Get the global service provider.
Definition: elgglib.php:343