ListenerAcceptor
in package
implements
ListenerAcceptorInterface
Table of Contents
Interfaces
Properties
- $emitter : EmitterInterface|null
- The emitter instance.
Methods
- __construct() : mixed
- Constructor
- addListener() : $this
- Add a listener for an event.
- addOneTimeListener() : $this
- Add a one time listener for an event.
Properties
$emitter
The emitter instance.
protected
EmitterInterface|null
$emitter
Methods
__construct()
Constructor
public
__construct(EmitterInterface $emitter) : mixed
Parameters
- $emitter : EmitterInterface
addListener()
Add a listener for an event.
public
addListener(mixed $event, mixed $listener[, mixed $priority = self::P_NORMAL ]) : $this
Parameters
- $event : mixed
- $listener : mixed
- $priority : mixed = self::P_NORMAL
Tags
Return values
$thisaddOneTimeListener()
Add a one time listener for an event.
public
addOneTimeListener(mixed $event, mixed $listener[, mixed $priority = self::P_NORMAL ]) : $this
Parameters
- $event : mixed
- $listener : mixed
- $priority : mixed = self::P_NORMAL