@param null|integer $iLang
@param null|bool    $blAdminMode

@return array
766703
public function getLanguageStrings($iLang = null, $blAdminMode = null)
    {
        $aLang = array();

        foreach ($this->_getLangTranslationArray($iLang, $blAdminMode) as $sLangKey => $sLangValue) {
            $aLang[$sLangKey] = $sLangValue;
        }

        foreach ($this->_getLanguageMap($iLang, $blAdminMode) as $sLangKey => $sLangValue) {
            $aLang[$sLangKey] = $sLangValue;
        }

        if (count($this->_aAdditionalLangFiles)) {
            foreach ($this->_getLangTranslationArray($iLang, $blAdminMode, $this->_aAdditionalLangFiles) as $sLangKey => $sLangValue) {
                $aLang[$sLangKey] = $sLangValue;
            }
        }

        return $aLang;
    }
463849
public char[] getMediumCBuffer(int minSize)
    {
        char[] result = null;
        if (mMediumCBuffer != null && mMediumCBuffer.length >= minSize) {
            result = mMediumCBuffer;
            mMediumCBuffer = null;
        }
//System.err.println("DEBUG: Alloc CMed: "+result);
        return result;
    }
747916
public function setTplLanguage($iLang = null)
    {
        $this->_iTplLanguageId = isset($iLang) ? (int) $iLang : $this->getBaseLanguage();
        if ($this->isAdmin()) {
            $aLanguages = $this->getAdminTplLanguageArray();
            if (!isset($aLanguages[$this->_iTplLanguageId])) {
                $this->_iTplLanguageId = key($aLanguages);
            }
        }

        \OxidEsales\Eshop\Core\Registry::getSession()->setVariable('tpllanguage', $this->_iTplLanguageId);

        return $this->_iTplLanguageId;
    }
982236
public function getBaseSeoLink($iLang, $iPage = 0)
    {
        $oEncoder = \OxidEsales\Eshop\Core\Registry::get(\OxidEsales\Eshop\Application\Model\SeoEncoderRecomm::class);
        if (!$iPage) {
            return $oEncoder->getRecommUrl($this, $iLang);
        }

        return $oEncoder->getRecommPageUrl($this, $iPage, $iLang);
    }
1095631
public function getCategoryAttributes($sCategoryId, $iLang)
    {
        $aSessionFilter = \OxidEsales\Eshop\Core\Registry::getSession()->getVariable('session_attrfilter');

        $oArtList = oxNew(\OxidEsales\Eshop\Application\Model\ArticleList::class);
        $oArtList->loadCategoryIDs($sCategoryId, $aSessionFilter);

        // Only if we have articles
        if (count($oArtList) > 0) {
            $oDb = \OxidEsales\Eshop\Core\DatabaseProvider::getDb();
            $sArtIds = '';
            foreach (array_keys($oArtList->getArray()) as $sId) {
                if ($sArtIds) {
                    $sArtIds .= ',';
                }
                $sArtIds .= $oDb->quote($sId);
            }

            $sActCatQuoted = $oDb->quote($sCategoryId);
            $sAttTbl = getViewName('oxattribute', $iLang);
            $sO2ATbl = getViewName('oxobject2attribute', $iLang);
            $sC2ATbl = getViewName('oxcategory2attribute', $iLang);

            $sSelect = "SELECT DISTINCT att.oxid, att.oxtitle, o2a.oxvalue " .
                       "FROM $sAttTbl as att, $sO2ATbl as o2a ,$sC2ATbl as c2a " .
                       "WHERE att.oxid = o2a.oxattrid AND c2a.oxobjectid = $sActCatQuoted AND c2a.oxattrid = att.oxid AND o2a.oxvalue !='' AND o2a.oxobjectid IN ($sArtIds) " .
                       "ORDER BY c2a.oxsort , att.oxpos, att.oxtitle, o2a.oxvalue";

            $rs = $oDb->select($sSelect);

            if ($rs != false && $rs->count() > 0) {
                while (!$rs->EOF && list($sAttId, $sAttTitle, $sAttValue) = $rs->fields) {
                    if (!$this->offsetExists($sAttId)) {
                        $oAttribute = oxNew(\OxidEsales\Eshop\Application\Model\Attribute::class);
                        $oAttribute->setTitle($sAttTitle);

                        $this->offsetSet($sAttId, $oAttribute);
                        $iLang = \OxidEsales\Eshop\Core\Registry::getLang()->getBaseLanguage();
                        if (isset($aSessionFilter[$sCategoryId][$iLang][$sAttId])) {
                            $oAttribute->setActiveValue($aSessionFilter[$sCategoryId][$iLang][$sAttId]);
                        }
                    } else {
                        $oAttribute = $this->offsetGet($sAttId);
                    }

                    $oAttribute->addValue($sAttValue);
                    $rs->fetchRow();
                }
            }
        }

        return $this;
    }
1258362
public function appendLink($sAddParams, $iLang = null)
    {
        if ($sAddParams) {
            if ($iLang === null) {
                $iLang = $this->getLanguage();
            }

            $this->_aSeoAddParams[$iLang] = isset($this->_aSeoAddParams[$iLang]) ? $this->_aSeoAddParams[$iLang] . "&amp;" : "";
            $this->_aSeoAddParams[$iLang] .= $sAddParams;
        }
    }
1030602
protected function _trimUrl($sUrl, $iLang = null)
    {
        $myConfig = \OxidEsales\Eshop\Core\Registry::getConfig();
        $oStr = getStr();
        $sUrl = str_replace([$myConfig->getShopUrl($iLang, false), $myConfig->getSslShopUrl($iLang)], '', $sUrl);
        $sUrl = $oStr->preg_replace('/(\?|&(amp;)?)(force_)?(admin_)?sid=[a-z0-9\.]+&?(amp;)?/i', '\1', $sUrl);
        $sUrl = $oStr->preg_replace('/(\?|&(amp;)?)shp=[0-9]+&?(amp;)?/i', '\1', $sUrl);
        $sUrl = $oStr->preg_replace('/(\?|&(amp;)?)lang=[0-9]+&?(amp;)?/i', '\1', $sUrl);
        $sUrl = $oStr->preg_replace('/(\?|&(amp;)?)cur=[0-9]+&?(amp;)?/i', '\1', $sUrl);
        $sUrl = $oStr->preg_replace('/(\?|&(amp;)?)stoken=[a-z0-9]+&?(amp;)?/i', '\1', $sUrl);
        $sUrl = $oStr->preg_replace('/(\?|&(amp;)?)&(amp;)?/i', '\1', $sUrl);
        $sUrl = $oStr->preg_replace('/(\?|&(amp;)?)+$/i', '', $sUrl);
        $sUrl = trim($sUrl);

        // max length <= $this->_iMaxUrlLength
        $iLength = $this->_getMaxUrlLength();
        if ($oStr->strlen($sUrl) > $iLength) {
            $sUrl = $oStr->substr($sUrl, 0, $iLength);
        }

        return $sUrl;
    }
1176024
public function getLevels(int $from = 1, ?int $to = null, ?callable $callback = null): array
    {
        $parts = explode('.', $this->env);
        $n = isset($to) ? min(count($parts), $to) : count($parts);

        $levels = [];

        for ($i = $from; $i <= $n; $i++) {
            $level = join('.', array_slice($parts, 0, $i));
            $levels[] = isset($callback) ? $callback($level) : $level;
        }

        return $levels;
    }
316797
protected function _getCacheLanguageId($blAdmin, $iLang = null)
    {
        $iLang = ($iLang === null && $blAdmin) ? $this->getTplLanguage() : $iLang;
        if (!isset($iLang)) {
            $iLang = $this->getBaseLanguage();
            if (!isset($iLang)) {
                $iLang = 0;
            }
        }

        return (int) $iLang;
    }
129087
public function getCandidatesList (bool $stringMode = false) : array
    {
        if (!$stringMode) :
            return $this->_Candidates;
        else :
            $result = [];

            foreach ($this->_Candidates as $candidateKey => &$oneCandidate) :
                $result[$candidateKey] = $oneCandidate->getName();
            endforeach;

            return $result;
        endif;
    }
14195
protected function _getStaticUri($sStdUrl, $iShopId, $iLang)
    {
        $sStdUrl = $this->_trimUrl($sStdUrl, $iLang);

        return $this->_loadFromDb('static', $this->_getStaticObjectId($iShopId, $sStdUrl), $iLang, $iShopId);
    }
896778
public function getBaseSeoLink($iLang)
    {
        return \OxidEsales\Eshop\Core\Registry::get(\OxidEsales\Eshop\Application\Model\SeoEncoderContent::class)->getContentUrl($this, $iLang);
    }
638137
public function getLocalRecordByILN ($iln)
    {
        foreach ($this->getLocalRecords() as $localRecord) {
            if ($localRecord->getILN() == $iln) {
                return $localRecord;
            }
        }
        return null;
    }
1239186
public function softParse(string $ini, bool $processSections = null, int $scannerMode = null): array
    {
        \assert('$scannerMode === null || $scannerMode >= 0');
        error_reporting(($before = error_reporting()) & ~E_WARNING);
        $content = parse_ini_string(
            $ini,
            $processSections ?? $this->processSections,
            $scannerMode ?? $this->scannerMode
        );
        error_reporting($before);
        if ($content === false) {
            return [null, new \InvalidArgumentException(sprintf("Invalid ini string \n\n%s\n", $ini))];
        }
        return [$content, null];
    }
64331
public function collect($restrictToModules = array(), $mergeWithExisting = false)
    {
        $entitiesByModule = $this->getEntitiesByModule();

        // Resolve conflicts between duplicate keys across modules
        $entitiesByModule = $this->resolveDuplicateConflicts($entitiesByModule);

        // Optionally merge with existing master strings
        if ($mergeWithExisting) {
            $entitiesByModule = $this->mergeWithExisting($entitiesByModule);
        }

        // Restrict modules we update to just the specified ones (if any passed)
        if (!empty($restrictToModules)) {
            // Normalise module names
            $modules = array_filter(array_map(function ($name) {
                $module = ModuleLoader::inst()->getManifest()->getModule($name);
                return $module ? $module->getName() : null;
            }, $restrictToModules));
            // Remove modules
            foreach (array_diff(array_keys($entitiesByModule), $modules) as $module) {
                unset($entitiesByModule[$module]);
            }
        }
        return $entitiesByModule;
    }
1319317
public function getLink($iLang = null)
    {
        $sLink = parent::getLink($iLang);

        // active category
        if ($sVal = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter('cnid')) {
            $sLink .= ((strpos($sLink, '?') === false) ? '?' : '&amp;') . "cnid={$sVal}";
        }

        // active article
        if ($sVal = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter('anid')) {
            $sLink .= ((strpos($sLink, '?') === false) ? '?' : '&amp;') . "anid={$sVal}";
        }

        return $sLink;
    }
1360844
public function getBaseSeoLink($iLang, $iPage = 0)
    {
        $oEncoder = \OxidEsales\Eshop\Core\Registry::get(\OxidEsales\Eshop\Application\Model\SeoEncoderCategory::class);
        if (!$iPage) {
            return $oEncoder->getCategoryUrl($this, $iLang);
        }

        return $oEncoder->getCategoryPageUrl($this, $iPage, $iLang);
    }