[ Index ]

PHP Cross Reference of phpBB-3.3.5-deutsch

title

Body

[close]

/vendor/zendframework/zend-eventmanager/src/Test/ -> EventListenerIntrospectionTrait.php (summary)

Zend Framework (http://framework.zend.com/)

Copyright: Copyright (c) 2005-2016 Zend Technologies USA Inc. (http://www.zend.com)
License: https://github.com/zendframework/zend-eventmanager/blob/master/LICENSE.md
File Size: 152 lines (5 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 5 functions

  getEventsFromEventManager()
  getListenersForEvent()
  assertListenerAtPriority()
  getArrayOfListenersForEvent()
  traverseListeners()

Functions
Functions that are not part of a class:

getEventsFromEventManager(EventManager $events)   X-Ref
Retrieve a list of event names from an event manager.

param: EventManager $events
return: string[]

getListenersForEvent($event, EventManager $events, $withPriority = false)   X-Ref
Retrieve an interable list of listeners for an event.

Given an event and an event manager, returns an iterator with the
listeners for that event, in priority order.

If $withPriority is true, the key values will be the priority at which
the given listener is attached.

Do not pass $withPriority if you want to cast the iterator to an array,
as many listeners will likely have the same priority, and thus casting
will collapse to the last added.

param: string $event
param: EventManager $events
param: bool $withPriority
return: \Traversable

assertListenerAtPriority(callable $expectedListener,$expectedPriority,$event,EventManager $events,$message = '')   X-Ref
Assert that a given listener exists at the specified priority.

param: callable $expectedListener
param: int $expectedPriority
param: string $event
param: EventManager $events
param: string $message Failure message to use, if any.

getArrayOfListenersForEvent($event, EventManager $events)   X-Ref
Returns an indexed array of listeners for an event.

Returns an indexed array of listeners for an event, in priority order.
Priority values will not be included; use this only for testing if
specific listeners are present, or for a count of listeners.

param: string $event
param: EventManager $events
return: callable[]

traverseListeners(array $queue, $withPriority = false)   X-Ref
Generator for traversing listeners in priority order.

param: array $listeners
param: bool $withPriority When true, yields priority as key.



Generated: Mon Oct 4 17:42:11 2021 Cross-referenced by PHPXref 0.7.1