PHP Класс Zend\Mvc\DispatchListener
Pulls controllers from the service manager's "ControllerLoader" service.
If the controller cannot be found, or is not dispatchable, sets up a "404"
result.
If the controller subscribes to InjectApplicationEventInterface, it injects
the current MvcEvent into the controller.
It then calls the controller's "dispatch" method, passing it the request and
response. If an exception occurs, it triggers the "dispatch.error" event,
in an attempt to return a 500 status.
The return value of dispatching the controller is placed into the result
property of the MvcEvent, and returned.
Показать файл
Открыть проект
Открытые методы
Защищенные методы
Описание методов
__construct()
публичный Метод
public __construct ( ControllerManager $controllerManager ) |
$controllerManager |
Zend\Mvc\Controller\ControllerManager |
|
Attach listeners to an event manager
public attach ( Zend\EventManager\EventManagerInterface $events, integer $priority = 1 ) : void |
$events |
Zend\EventManager\EventManagerInterface |
|
$priority |
integer |
|
Результат |
void |
|
complete()
защищенный Метод
marshalBadControllerEvent()
защищенный Метод
Marshal a bad controller exception event
marshalControllerNotFoundEvent()
защищенный Метод
Marshal a controller not found exception event
onDispatch()
публичный Метод
Listen to the "dispatch" event
reportMonitorEvent()
публичный Метод