public static function createControllerFromRoute(Route $route, array $parameters = null) {

		$controllerClass = Application::getInstance()->getApplicationNamespace() . $route->getControllerClassName();

		/**
		 * @var Controller
		 */
		$instance = new $controllerClass($route, $parameters); 
		
		if($method = $instance->route->getMethodName()) {
			$instance->setExecutedMethod($method);
		}
		else {
			$instance->setExecutedMethod('execute');
		}

		return $instance;

	}
public static function createControllerFromRoute(Route $route, array $parameters = null) {

		$controllerClass = Application::getInstance()->getApplicationNamespace() . $route->getControllerClassName();

		/**
		 * @var Controller
		 */
		$instance = new $controllerClass($route, $parameters); 
		
		if($method = $instance->route->getMethodName()) {
			$instance->setExecutedMethod($method);
		}
		else {
			$instance->setExecutedMethod('execute');
		}

		return $instance;

	}
public static function createControllerFromRoute ( Route $ route , array $ parameters = null ) { $ controllerClass = Application :: getInstance ( ) -> getApplicationNamespace ( ) . $ route -> getControllerClassName ( ) ; /**
		 * @var Controller
		 */ $ instance = new $ controllerClass ( $ route , $ parameters ) ; if ( $ method = $ instance -> route -> getMethodName ( ) ) { $ instance -> setExecutedMethod ( $ method ) ; } else { $ instance -> setExecutedMethod ( 'execute' ) ; } return $ instance ; }
determines controller class name from a routes controllerString
property and returns a controller instance
an additional parameters array will be passed on to the constructor

@param Route $route
@param array $parameters
@return \vxPHP\Controller\Controller
@throws \vxPHP\Application\Exception\ApplicationException
determines controller class name from a routes controllerString property and returns a controller instance an additional parameters array will be passed on to the constructor