Skip to content

ListenerPriorityQueue

  • Full name: \Qubus\EventDispatcher\Legacy\ListenerPriorityQueue
  • This class implements: \IteratorAggregate

Properties

storage

protected \SplObjectStorage $storage

queue

protected \SplPriorityQueue $queue

Methods

__construct

public __construct(\SplObjectStorage $storage = new SplObjectStorage(), \SplPriorityQueue $queue = new SplPriorityQueue()): mixed

Parameters:

Parameter Type Description
$storage \SplObjectStorage
$queue \SplPriorityQueue

insert

Insert a listener to the queue.

public insert(\Qubus\EventDispatcher\Legacy\EventListener $listener, int $priority): void

Parameters:

Parameter Type Description
$listener \Qubus\EventDispatcher\Legacy\EventListener
$priority int

detach

Removes an listener from the queue.

public detach(\Qubus\EventDispatcher\Legacy\EventListener $listener): void

Parameters:

Parameter Type Description
$listener \Qubus\EventDispatcher\Legacy\EventListener

clear

Clears the queue.

public clear(): void

contains

Checks whether the queue contains the listener.

public contains(\Qubus\EventDispatcher\Legacy\EventListener $listener): bool

Parameters:

Parameter Type Description
$listener \Qubus\EventDispatcher\Legacy\EventListener

all

Gets all listeners.

public all(): \Qubus\EventDispatcher\Legacy\EventListener[]

getIterator

Clones and returns a iterator.

public getIterator(): \Traversable

refreshQueue

Refreshes the status of the queue.

protected refreshQueue(): void


Automatically generated on 2025-10-13