From 069a655032770e2dc8049e0f3bc07996cef3e816 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Thu, 18 May 2017 23:29:20 +0200 Subject: [PATCH] Next wave: - imported (Base)ControllerResolver - imported ManageableApplication - created new namespaces - fixed namespaces, is application-specific MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- application/hub/class_ApplicationHelper.php | 2 +- .../console/class_HubConsoleCommandResolver.php | 6 ++++++ .../command/html/class_HubHtmlCommandResolver.php | 6 ++++++ .../console/class_HubConsoleControllerResolver.php | 10 +++++++++- .../html/class_HubHtmlControllerResolver.php | 10 +++++++++- 5 files changed, 31 insertions(+), 3 deletions(-) diff --git a/application/hub/class_ApplicationHelper.php b/application/hub/class_ApplicationHelper.php index 1ef110253..56c008135 100644 --- a/application/hub/class_ApplicationHelper.php +++ b/application/hub/class_ApplicationHelper.php @@ -230,7 +230,7 @@ class ApplicationHelper extends BaseFrameworkSystem implements ManageableApplica // Get a controller resolver $resolverClass = sprintf( - 'CoreFramework\Tests\Resolver\Controller\%s', + 'Hub\Resolver\Controller\%s', self::convertToClassName(sprintf( '%s_%s_controller_resolver', $this->getAppShortName(), diff --git a/application/hub/classes/resolver/command/console/class_HubConsoleCommandResolver.php b/application/hub/classes/resolver/command/console/class_HubConsoleCommandResolver.php index 2343d40c4..5a4baacd4 100644 --- a/application/hub/classes/resolver/command/console/class_HubConsoleCommandResolver.php +++ b/application/hub/classes/resolver/command/console/class_HubConsoleCommandResolver.php @@ -1,4 +1,10 @@ isControllerValid($controllerName) === FALSE) { + } elseif ($resolverInstance->isControllerValid('Hub\Controller', $controllerName) === false) { // Invalid command found throw new InvalidControllerException(array($resolverInstance, $controllerName), self::EXCEPTION_INVALID_CONTROLLER); } diff --git a/application/hub/classes/resolver/controller/html/class_HubHtmlControllerResolver.php b/application/hub/classes/resolver/controller/html/class_HubHtmlControllerResolver.php index 1376a827e..cc54da23a 100644 --- a/application/hub/classes/resolver/controller/html/class_HubHtmlControllerResolver.php +++ b/application/hub/classes/resolver/controller/html/class_HubHtmlControllerResolver.php @@ -1,4 +1,12 @@ isControllerValid($controllerName) === FALSE) { + } elseif ($resolverInstance->isControllerValid('Hub\Controller', $controllerName) === false) { // Invalid command found throw new InvalidControllerException(array($resolverInstance, $controllerName), self::EXCEPTION_INVALID_CONTROLLER); } -- 2.39.5