From eee0a766aa0027fe6b55c5988484e0cac6be17b9 Mon Sep 17 00:00:00 2001 From: jld3103 Date: Fri, 24 Mar 2023 12:54:30 +0100 Subject: [PATCH] Add stubs Signed-off-by: jld3103 --- build/stubs/ini_get_wrapper.php | 5 ++ build/stubs/psr_clock.php | 13 ++++ build/stubs/psr_container.php | 52 ++++++++++++++++ build/stubs/psr_eventdispatcher.php | 59 +++++++++++++++++++ build/stubs/sabre_dav_exception.php | 7 +++ .../symfony_component_eventdispatcher.php | 28 +++++++++ psalm-ocp.xml | 1 + psalm.xml | 6 ++ 8 files changed, 171 insertions(+) create mode 100644 build/stubs/ini_get_wrapper.php create mode 100644 build/stubs/psr_clock.php create mode 100644 build/stubs/psr_container.php create mode 100644 build/stubs/psr_eventdispatcher.php create mode 100644 build/stubs/sabre_dav_exception.php create mode 100644 build/stubs/symfony_component_eventdispatcher.php diff --git a/build/stubs/ini_get_wrapper.php b/build/stubs/ini_get_wrapper.php new file mode 100644 index 0000000000000..b8f1c05a7495c --- /dev/null +++ b/build/stubs/ini_get_wrapper.php @@ -0,0 +1,5 @@ + + * An iterable (array, iterator, or generator) of callables. Each + * callable MUST be type-compatible with $event. + */ + public function getListenersForEvent(object $event) : iterable; +} + +/** + * An Event whose processing may be interrupted when the event has been handled. + * + * A Dispatcher implementation MUST check to determine if an Event + * is marked as stopped after each listener is called. If it is then it should + * return immediately without calling any further Listeners. + */ +interface StoppableEventInterface +{ + /** + * Is propagation stopped? + * + * This will typically only be used by the Dispatcher to determine if the + * previous listener halted propagation. + * + * @return bool + * True if the Event is complete and no further listeners should be called. + * False to continue calling listeners. + */ + public function isPropagationStopped() : bool; +} diff --git a/build/stubs/sabre_dav_exception.php b/build/stubs/sabre_dav_exception.php new file mode 100644 index 0000000000000..ced9b84028f83 --- /dev/null +++ b/build/stubs/sabre_dav_exception.php @@ -0,0 +1,7 @@ + + diff --git a/psalm.xml b/psalm.xml index 47b486d51a19e..f337580ffc0cd 100644 --- a/psalm.xml +++ b/psalm.xml @@ -79,6 +79,12 @@ + + + + + +