Open weierophinney opened 3 years ago
@weierophinney @Xerkus any thoughts when this can be released?
@chris1312 I need to find time to document and create migration documentation (and/or scripts). It's a pretty big change, and I've been swamped with the migration to github actions, unfortunately.
Roger that. Thanks for the update!
Description
This patch adapts
EventManager
to work as a PSR-14 EventDispatcher. It does so by doing the following:ListenerProvider
subnamespace; this includes both the listener attachment previously in theEventManager
instance as well as theSharedEventManager
instance.ListenerProvider
subnamespace.EventManager
to consume listener providers. By default, it will create a default priority-based listener provider, and have its various listener attachment methods proxy to that provider; it then aggregates that provider with theSharedEventManager
(which is itself a provider now) in order to retrieve listeners. This is done in such a way that behavior is completely backwards compatible with current usage.createUsingListenerProvider()
, allows providing a specific listener provider for use with theEventManager
. If the provider is attachment capable, the various listener attachment methods will proxy to it; otherwise, they will raise an exception.The patch also deprecates a number of features, including:
EventInterface
.TODO
Fixes #2