PocketMine-MP 5.23.3 git-f7687af337d001ddbcc47b8e773f014a33faa662
Loading...
Searching...
No Matches
pocketmine\event\HandlerList Class Reference
+ Collaboration diagram for pocketmine\event\HandlerList:

Public Member Functions

 __construct (private string $class, private ?HandlerList $parentList, private RegisteredListenerCache $handlerCache=new RegisteredListenerCache())
 
 clear ()
 
 getListenerList ()
 
 getListenersByPriority (int $priority)
 
 getParent ()
 
 register (RegisteredListener $listener)
 
 registerAll (array $listeners)
 
 unregister (RegisteredListener|Plugin|Listener $object)
 

Detailed Description

Definition at line 32 of file HandlerList.php.

Constructor & Destructor Documentation

◆ __construct()

pocketmine\event\HandlerList::__construct ( private string $class,
private ?HandlerList $parentList,
private RegisteredListenerCache $handlerCache = new RegisteredListenerCache() )

@phpstan-param class-string<covariant Event> $class

Definition at line 45 of file HandlerList.php.

Member Function Documentation

◆ clear()

pocketmine\event\HandlerList::clear ( )

Definition at line 93 of file HandlerList.php.

◆ getListenerList()

pocketmine\event\HandlerList::getListenerList ( )
Returns
RegisteredListener[] @phpstan-return list<RegisteredListener>

Definition at line 122 of file HandlerList.php.

◆ getListenersByPriority()

pocketmine\event\HandlerList::getListenersByPriority ( int $priority)
Returns
RegisteredListener[]

Definition at line 101 of file HandlerList.php.

◆ getParent()

pocketmine\event\HandlerList::getParent ( )

Definition at line 105 of file HandlerList.php.

◆ register()

pocketmine\event\HandlerList::register ( RegisteredListener $listener)
Exceptions

Exception

Definition at line 58 of file HandlerList.php.

◆ registerAll()

pocketmine\event\HandlerList::registerAll ( array $listeners)
Parameters
RegisteredListener[]$listeners

Definition at line 69 of file HandlerList.php.

◆ unregister()

pocketmine\event\HandlerList::unregister ( RegisteredListener|Plugin|Listener $object)

Definition at line 76 of file HandlerList.php.


The documentation for this class was generated from the following file: