Ищет среди дочерних разделов раздел с заданным алиасом

@api
@param string @alias алиас раздела
@return Catalog|FALSE
352200
public function findChildByAlias($alias)
    {
		$id = self::getDbConnection()->fetchColumn("select A.id from dir_data A, dir_structure B, dir_structure C where C.data_id=? and B.data_id=A.id and B.lft BETWEEN C.lft and C.rght and A.tablename=?", array($this->id, $alias));
        if ($id) {
            return Catalog::getById($id);
        } else return FALSE;
    }
105602
public function syncCatalog()
    {
        try {
            //remove product with product id set and no product
            $this->catalogResourceFactory->create()
                ->removeOrphanProducts();

            return $this->catalogSyncFactory->create()->sync();

        } catch (\Exception $e) {
            $this->helper->debug((string)$e, []);
        }
    }
1279361
function alias($name,$params=NULL,$lang=NULL) {
		if (in_array($name,$this->global_aliases))
			return $this->f3->alias($name,$params);
		if (!is_array($params))
			$params=$this->f3->parse($params);
		if (!$lang)
			$lang=$this->current;
		if (isset($this->rules[$lang][$name]) && $this->rules[$lang][$name]===FALSE)
			return FALSE;
		$url=isset($this->rules[$lang][$name])?
			$this->rules[$lang][$name]:@$this->_aliases[$name];
		if (!$url)
			user_error(sprintf(\Base::E_Named,$name),E_USER_ERROR);
		return $this->f3->build(rtrim('/'.$lang.$url,'/'),$params);
	}
783743
function alias( $aliasName )
    {
        $aliasList = $this->aliasList();
        if ( !array_key_exists( $aliasName, $aliasList ) )
            return false;
        return $aliasList[$aliasName];
    }
1076673
public function search($query) {
        global $CFG;
        if ($result = parent::search($query)) {
            return $result;
        }

        $found = false;
        $repositories= core_component::get_plugin_list('repository');
        foreach ($repositories as $p => $dir) {
            if (strpos($p, $query) !== false) {
                $found = true;
                break;
            }
        }
        if (!$found) {
            foreach (repository::get_types() as $instance) {
                $title = $instance->get_typename();
                if (strpos(core_text::strtolower($title), $query) !== false) {
                    $found = true;
                    break;
                }
            }
        }

        if ($found) {
            $result = new stdClass();
            $result->page     = $this;
            $result->settings = array();
            return array($this->name => $result);
        } else {
            return array();
        }
    }
1295279
public function getCatalogIndex($projectId = null)
    {
        return $this->callService($this->url_plan['get_catalog_index'], array(
                'project_id' => $projectId ?: $this->project_id,
            )
        );
    }
1261727
public function setCatalog( $catalog )
    {
        if (is_a($catalog,'Cetera\\Catalog') || is_a($catalog,'Cetera\\Server')) {
            $this->_catalog = $catalog;
            return;
        }
        if (is_int($catalog)) {
            $this->_catalog = Catalog::getById($catalog);
            return;        
        }
    }
633839
public function getCatalogs($locale = null, $domain = null) {
		if ($locale === null && $domain === null) {
			return $this->catalogs;
		}
		
		if (is_string($locale)) {
			return $this->getSingleCatalog($locale, $domain);
		}
		
		if (is_array($locale)) {
			return $this->getManyCatalogs($locale, $domain);
		}
		
		throw new InvalidParameter('Locale must be a string or an array');
	}
1229601
public function get($name = null)
    {
        if ($name === null) {
            return $this->_aliases;
        }

        if ($name[0] !== '@') {
            throw new MisuseException(['`:name` must start with `@`', 'name' => $name]);
        }

        return isset($this->_aliases[$name]) ? $this->_aliases[$name] : false;
    }
440579
public static function getEntityClassByAlias(string $alias, QueryBuilder $queryBuilder, ManagerRegistry $managerRegistry): string
    {
        if (!\in_array($alias, $queryBuilder->getAllAliases(), true)) {
            throw new \LogicException(sprintf('The alias "%s" does not exist in the QueryBuilder.', $alias));
        }

        $rootAliasMap = self::mapRootAliases($queryBuilder->getRootAliases(), $queryBuilder->getRootEntities());

        if (isset($rootAliasMap[$alias])) {
            return $rootAliasMap[$alias];
        }

        $metadata = null;

        foreach (self::traverseJoins($alias, $queryBuilder, $managerRegistry) as [$currentMetadata]) {
            $metadata = $currentMetadata;
        }

        if (null === $metadata) {
            throw new \LogicException(sprintf('The alias "%s" does not exist in the QueryBuilder.', $alias));
        }

        return $metadata->getName();
    }
265747
public function find($url)
    {
        $catalogue = $this->getCatalogue();

        if ($catalogue instanceof ComActivitiesActivityTranslatorCatalogueInterface)
        {
            // Locate files using fallback locale
            $locale  = $this->getLocaleFallback();
            $locator = $this->getObject('translator.locator.factory')->createLocator($url);
            $result  = $locator->setLocale($locale)->locate($url, $locale);
        }
        else $result = $this->getDelegate()->find($url);

        return $result;
    }
1098343
public function load($alias)
    {
        if (isset($this->aliases[$alias])) {
            return class_alias($this->aliases[$alias], $alias);
        }
        return null;
    }
1124231
public static function get_opt($aliases = array())
    {
        $args = array();
        $bool = array();

        // find boolean (no value) options
        foreach ($aliases as $key => $alias) {
            if ($pos = strpos($alias, ':')) {
                $aliases[$key] = substr($alias, 0, $pos);
                $bool[] = $key;
                $bool[] = $aliases[$key];
            }
        }

        for ($i=1; $i < count($_SERVER['argv']); $i++) {
            $arg   = $_SERVER['argv'][$i];
            $value = true;
            $key   = null;

            if ($arg[0] == '-') {
                $key = preg_replace('/^-+/', '', $arg);
                $sp  = strpos($arg, '=');

                if ($sp > 0) {
                    $key   = substr($key, 0, $sp - 2);
                    $value = substr($arg, $sp+1);
                }
                else if (in_array($key, $bool)) {
                    $value = true;
                }
                else if (strlen($_SERVER['argv'][$i+1]) && $_SERVER['argv'][$i+1][0] != '-') {
                    $value = $_SERVER['argv'][++$i];
                }

                $args[$key] = is_string($value) ? preg_replace(array('/^["\']/', '/["\']$/'), '', $value) : $value;
            }
            else {
                $args[] = $arg;
            }

            if ($alias = $aliases[$key]) {
                $args[$alias] = $args[$key];
            }
        }

        return $args;
    }
83868
public function resolve($alias)
	{
		// Check wether the alias matches the pattern
		if ( ! preg_match($this->regex, $alias, $matches))
		{
			return false;
		}

		// Get the translation
		$translation = $this->translation;

		if (strpos($translation, '$') === false)
		{
			$class = $translation;
		}
		else
		{
			// Make sure namespace seperators are escaped
			$translation = str_replace('\\', '\\\\', $translation);

			// Resolve the replacement
			$class = preg_replace($this->regex, $translation, $alias);
		}

		// Check wether the class exists
		if ($class and $this->objectExists($class, true))
		{
			return $class;
		}

		return false;
	}
211642
static function get($alias = null)
    {
        if ($alias === null) {
            return static::$config[static::$default];
        }
        if (isset(static::$config[$alias])) {
            return static::$config[$alias];
        } else {
            return false;
        }
    }
1079800
public function resolveNamespaceAlias(string $alias)
    {
        foreach ($this->namespaces as $namespace) {
            list($className, $aliasTo) = $namespace;

            if (false == strpos($alias, $aliasTo)) {
                if (!empty($aliasTo)) {
                    $alias = substr($alias, strlen($aliasTo) + 1);
                }

                return $this->getClassForNamespaceAlias($className.'\\'.$alias);
            }
        }

        return false;
    }
837351
public static function clear($alias = null)
	{
		$obj = self::getInstance($alias);
		if ($obj)
		{
			return $obj->clear();
		}
		else
		{
			return false;
		}
	}