1<?php 2// (c) Copyright by authors of the Tiki Wiki CMS Groupware Project 3// 4// All Rights Reserved. See copyright.txt for details and a complete list of authors. 5// Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See license.txt for details. 6// $Id$ 7 8class Tiki_Event_Chain implements Tiki_Event_EdgeProvider 9{ 10 private $event; 11 private $manager; 12 13 function __construct(Tiki_Event_Manager $manager, $eventName) 14 { 15 $this->event = $eventName; 16 $this->manager = $manager; 17 } 18 19 function __invoke($arguments, $eventName, $priority) 20 { 21 $this->manager->internalTrigger($this->event, $arguments, $priority, $eventName); 22 } 23 24 function getTargetEvents() 25 { 26 return [$this->event]; 27 } 28} 29