getController() публичный Метод

public getController ( string $module, string | null $action, array &$parameters ) : callable
$module string
$action string | null
$parameters array
Результат callable The controller is a PHP callable.
Пример #1
0
 /**
  * @param array $widget
  *
  * @dataProvider availableWidgetsProvider
  */
 public function test_WidgetIsRenderable_ToPreventBreakingTheAPI($widget)
 {
     $params = $widget['parameters'];
     $parameters = array();
     $resolver = new ControllerResolver(StaticContainer::getContainer());
     $controller = $resolver->getController($params['module'], $params['action'], $parameters);
     $this->assertNotEmpty($controller, $widget['name'] . ' is not renderable with following params: ' . json_encode($params) . '. This breaks the API, please make sure to keep the URL working');
 }