public function registerController($controller, $applicationName = 'default')
    {
    	if ( !$controller instanceof \Nkey\Caribu\Mvc\Controller\AbstractController ) {
	        if (! class_exists($controller)) {
	            throw new ControllerException("No such controller class {controller} found", array(
	                'controller' => $controller
	            ));
	        }
	        $c = new $controller();
	        if (! ($c instanceof AbstractController)) {
	            throw new ControllerException("Controller {controller} is not in application scope", array(
	                'controller' => $controller
	            ));
	        }
    	}
        else {
        	$c = $controller;
        }
        $settings = $c->getControllerSettings();
        $this->controllers[$applicationName][$settings->getControllerSimpleName()] = $settings;
        
        return $this;
    }