Extract requested controller key.
In case the key makes sense (we find a matching class) it will be returned.

@return mixed|null
1140
protected function getRequestedControllerKey()
    {
        $return = null;
        $requestedControllerKey = $this->getRequest()->getRequestParameter('oePayPalRequestedControllerKey');
        if (!empty($requestedControllerKey) &&
            \OxidEsales\Eshop\Core\Registry::getControllerClassNameResolver()->getClassNameById($requestedControllerKey)) {
            $return = $requestedControllerKey;
        }
        return $return;
    }
998860
public static function get($controllerClass) {
        if (!isset(self::$controllers[$controllerClass])) {
            if (class_exists($controllerClass)) {
                $reflectionClass = new ReflectionClass($controllerClass);
                self::$controllers[$controllerClass] = $reflectionClass->isAbstract()? $controllerClass : (new $controllerClass);
            }
            else {
                self::$controllers[$controllerClass] = null;
            }
        }
        return self::$controllers[$controllerClass];
    }
847689
public function detectController($class_name = null)
    {

        // Setup the two schemes
        if (!$class_name) {
            $class_name = $this->detectControllerClass();
        }
        $app = 'App\\Http\\Controllers\\'
            . ucfirst(Str::studly($this->dir))
            . '\\'.$class_name;
        $decoy = 'Bkwld\Decoy\Controllers\\'.$class_name;

        // Find the right one
        if (class_exists($app)) {
            return $app;
        } elseif (class_exists($decoy)) {
            return $decoy;
        }

        return false;
    }
797000
protected function _getKey()
    {
        $view = $this->getView();
        $key  = $view->getIdentifier().'-'.$view->getLayout();

        if ($this->getMixer() instanceof KControllerModellable)
        {
            $state = $this->getModel()->getState()->getValues();
            $key  .= ':'.md5(http_build_query($state, '', '&'));
        }

        return $key;
    }
960930
public function getControllerName()
    {
        //default controller for SiteTree objects
        $controller = CatalogueController::class;

        //go through the ancestry for this class looking for
        $ancestry = ClassInfo::ancestry($this->owner->ClassName);

        // loop over the array going from the deepest descendant (ie: the current class) to SiteTree
        while ($class = array_pop($ancestry)) {
            //we don't need to go any deeper than the SiteTree class
            if ($class == CatalogueProduct::class || $class == CatalogueCategory::class) {
                break;
            }
            
            // If we have a class of "{$ClassName}Controller" then we found our controller
            if (class_exists($candidate = sprintf('%sController', $class))) {
                $controller = $candidate;
                break;
            } elseif (class_exists($candidate = sprintf('%s_Controller', $class))) {
                // Support the legacy underscored filename, but raise a deprecation notice
                Deprecation::notice(
                    '5.0',
                    'Underscored controller class names are deprecated. Use "MyController" instead of "My_Controller".',
                    Deprecation::SCOPE_GLOBAL
                );
                $controller = $candidate;
                break;
            }
        }

        return $controller;
    }
601799
protected function getSessionKeyByOwner()
    {
        if ($this->sessionKey) {
            return $this->sessionKey;
        }

        if ($this->owner instanceof Controller) {
            return $this->owner->module->id;
        }

        return 'generic';
    }
881928
public function getController()
    {
        if (isset($this->uris[0]) && '' !== $this->uris[0]) {
            $_controller = $this->uris[0];
        } else {
            throw new NotFoundException('Cannot dispatch controller name.');
        }

        return strip_tags($_controller);
    }
1228357
public function find($url)
    {
        if (!array_key_exists($url, $this->controllerMap)) {
            return null;
        }

        return $this->controllerMap[$url];
    }
593114
public function getController()
    {

        $class = overrideable_core_class('Core\\Antispam\\'
            . camelcase($this->saslHandle) . 'Controller', DIRNAME_CLASSES . '/Antispam/'
            . camelcase($this->saslHandle) . 'Controller.php',
            $this->getPackageHandle()
        );
        $app = Facade::getFacadeApplication();
        $cl = $app->make($class);
        return $cl;
    }
834051
protected function getCacheKey()
	{
		if($this->_key!==null)
			return $this->_key;
		else
		{
			$key=$this->getBaseCacheKey().'.';
			if($this->varyByRoute)
			{
				$controller=$this->getController();
				$key.=$controller->getUniqueId().'/';
				if(($action=$controller->getAction())!==null)
					$key.=$action->getId();
			}
			$key.='.';

			if($this->varyBySession)
				$key.=Yii::app()->getSession()->getSessionID();
			$key.='.';

			if(is_array($this->varyByParam) && isset($this->varyByParam[0]))
			{
				$params=array();
				foreach($this->varyByParam as $name)
				{
					if(isset($_GET[$name]))
						$params[$name]=$_GET[$name];
					else
						$params[$name]='';
				}
				$key.=serialize($params);
			}
			$key.='.';

			if($this->varyByExpression!==null)
				$key.=$this->evaluateExpression($this->varyByExpression);
			$key.='.';

			if($this->varyByLanguage)
				$key.=Yii::app()->language;
			$key.='.';

			return $this->_key=$key;
		}
	}
565468
public function getRoute()
    {
        /** @var Http $req */
        $req = $this->context->getRequest();
        if (isset($this->map[$req->getControllerName()])) {
            return $this->map[$req->getControllerName()];
        }

        return $this->map[Generic::CONTROLLER_KEY];
    }
764687
protected function calculateControllerClassFromRights()
    {
        $this->user(); //init user first;
        $controllerClass = $this->getControllerClassFromNameAndModule($this->request()->getController(), $this->request()->getModule());
        if (!trim($this->request()->getAction())) {
            $ctrl = new $controllerClass;
            /* @var $ctrl \mpf\web\Controller */
            $this->request()->setAction($ctrl->defaultAction);

        }
        if (!class_exists($controllerClass)) {
            if ($this->logMissingPages) {
                $this->alert('Controller ' . $controllerClass . ' not found!', array(
                    'requestedController' => $this->request()->getController(),
                    'requestedModule' => $this->request()->getModule()
                ));
            }
            $controllerClass = $this->getPageNotFound();
        } elseif ($this->accessMap && (!$this->accessMap->canAccess($this->request()->getController(), $this->request()->getAction(), $this->request()->getModule()))) {
            if ($this->user()->isGuest()) { // it's not loggedin , redirect to login page
                $controllerClass = $this->getPageLogin();
            } else { // it's loggedin but doesn't have the rights, redirect to access denied page
                $controllerClass = $this->getPageAccessDenied();
            }
        }
        return $controllerClass;
    }
30029
public function getController($method)
    {
        if (is_null($this->_controller)) {
            $className = $this->_routeInfo->getController();
            if (!class_exists($className)) {
                throw new Exception\ControllerNotFoundException(
                    "Controller '{$className}' not found"
                );
            }

            $options = array(
                'request' => $this->_application->getRequest(),
                'response' => $this->_application->getResponse(),
            );

            /** @var Controller $instance */
            $instance = new $className($options);
            $methodExists = method_exists($instance,$method);
            $this->_controller = $instance;
            if (!$methodExists && $instance->isScaffold()) {
                $this->_controller = Scaffold::getScaffoldController(
                    $instance
                );
            }
        }
        return $this->_controller;
    }
1327657
public static function findControllerID()
    {
        if (empty($_REQUEST[self::KEY_ID])
            || empty($_SESSION[sprintf(self::KEY_CONTAINER, $_REQUEST[self::KEY_ID])])
        ) {
            return null;
        } else {
            return $_REQUEST[self::KEY_ID];
        }
    }
888925
protected function getRequest()
    {
        // Check if current request handler has a request object
        $controller = $this->getController();
        if ($controller && !($controller->getRequest() instanceof NullHTTPRequest)) {
            return $controller->getRequest();
        }
        // Fall back to current controller
        if (Controller::has_curr() && !(Controller::curr()->getRequest() instanceof NullHTTPRequest)) {
            return Controller::curr()->getRequest();
        }
        return null;
    }
764119
protected function getSessionKey()
	{
		return self::SESSION_VAR_PREFIX . Yii::app()->getId() . '.' . $this->getController()->getUniqueId() . '.' . $this->getId();
	}
573161
public function getControllerName()
    {
        if (empty($this->controller_name)) {
            $controller_class = get_class($this);

            if (($pos = strrpos($controller_class, '\\')) !== false) {
                $this->controller_name = substr($controller_class, $pos + 1);
            } else {
                $this->controller_name = $controller_class;
            }
        }

        return $this->controller_name;
    }