Newscoop\Doctrine\EventDispatcherProxy::getSubscribedEvents PHP Method

getSubscribedEvents() public method

Get subscribed doctrine orm events.
public getSubscribedEvents ( ) : array
return array
    public function getSubscribedEvents()
    {
        return array(Events::postPersist, Events::postUpdate, Events::preRemove);
    }

Usage Example

 public function testGetSubscribedEvents()
 {
     $this->assertEquals(array(Events::postPersist, Events::postUpdate, Events::preRemove), $this->proxy->getSubscribedEvents());
     foreach ($this->proxy->getSubscribedEvents() as $event) {
         $this->assertTrue(is_callable(array($this->proxy, $event)), "{$event} is not callable");
     }
 }