示例#1
0
 public function testAction(TestEventDispatcherService $dispatcher)
 {
     $data = array();
     $testEvent = new TestEvent($data);
     $dispatcher->dispatch(TestEvents::SAVE_ACTION, $testEvent);
 }
示例#2
0
 protected function addSubscriber()
 {
     $subscriber = new TestEventSubscriber();
     $this->dispatcherObject->addSubscriber($subscriber);
 }