Exemplo n.º 1
0
Arquivo: Event.php Projeto: rezon/sugi
 public static function fire($eventName, array $params = array())
 {
     $dispatcher = static::_getInstance();
     $event = new Evnt($eventName, $params);
     $event->setDispatcher($dispatcher);
     $dispatcher->dispatch($event);
 }
Exemplo n.º 2
0
 public function testSetParam()
 {
     $event = new Event("user.login");
     $event->setParam("username", "demo");
     $this->assertSame("demo", $event->getParam("username"));
 }