EventObserverProxy
class EventObserverProxy implements ObserverInterface
Class EventObserverProxy
This proxy class will try to always construct an object
compliant with the ObserverInterface
. It uses a simple
callback
property that can be:
- a "real"
ObserverInterface
object - another object with a
handleEvent( EventInterface $event )
method - an array like
array( class , method )
to call a specific method - a closure to call when the event is fired
Methods
__construct(
callable|null $callback = null)
No description
$this
setCallback(
callable|array $callback)
No description
void
handleEvent(
EventInterface $event)
No description