protected function detectLanguage($lang, $request)
    {
        $lang = $this->setLanguagInSession($lang);

        $this->sessionValues = $_SESSION[self::SESSION_PARAMETER_LANGUAGE_COMPONENT];

        $this->checkForceRedirect($lang, $request);
    }
protected function detectLanguage($lang, $request)
    {
        $lang = $this->setLanguagInSession($lang);

        $this->sessionValues = $_SESSION[self::SESSION_PARAMETER_LANGUAGE_COMPONENT];

        $this->checkForceRedirect($lang, $request);
    }
protected function detectLanguage ( $ lang , $ request ) { $ lang = $ this -> setLanguagInSession ( $ lang ) ; $ this -> sessionValues = $ _SESSION [ self :: SESSION_PARAMETER_LANGUAGE_COMPONENT ] ; $ this -> checkForceRedirect ( $ lang , $ request ) ; }
Check if the found language is allowed and
if an action is to be taken.

@param $lang
@param Request $request
Check if the found language is allowed and if an action is to be taken .