dispatch("hook_civicrm_post::" . $event->entity, $event); } /** * One of: 'create'|'edit'|'delete' * * @var string */ public $action; /** * @var string */ public $entity; /** * @var int|null */ public $id; /** * @var Object */ public $object; /** * Class constructor * * @param string $action * @param string $entity * @param int $id * @param object $object */ public function __construct($action, $entity, $id, &$object) { $this->action = $action; $this->entity = $entity; $this->id = $id; $this->object = &$object; } /** * @inheritDoc */ public function getHookValues() { return [$this->action, $this->entity, $this->id, &$this->object]; } }