Returns a node hydrated with its children and parents

@api

@param string $path
@param string $rootAlias
@param array  $extraParams To be used in addFlatTreeConditions

@return NodeInterface a node
489715
public function getTree($path = '', $rootAlias = 't', $extraParams = array())
    {
        $results = $this->getFlatTree($path, $rootAlias, $extraParams);

        return $this->buildTree($results);
    }
1008352
protected function resolvePath($pathPropertyName, array $extras = [])
    {
        $resolvedPaths = $this->getResolvedPaths();
        $basePath = base_path();
        $publicPath = public_path();
        $extras = array_merge(compact('basePath', 'publicPath'), $extras);

        return Util::template($resolvedPaths[ $pathPropertyName ], $extras);
    }
600011
protected function getOrCreateByPath($path, EloquentFile $parentNode=null)
    {
        $node = $this->getOrMakeByPath($path, $parentNode);

        if (!$node->getId()) {
            $this->save($node);
        }

        return $node;

    }
1194090
protected function buildFileList( $path, $extraFilter = null )
    {
        $dirSep = preg_quote( DIRECTORY_SEPARATOR );
        $exclusionFilter = array( "@^{$path}{$dirSep}(var|settings|benchmarks|bin|autoload|port_info|update|templates|tmp|UnitTest|lib{$dirSep}ezc)@" );

        if ( !empty( $extraFilter ) and is_array( $extraFilter ) )
        {
            foreach( $extraFilter as $filter )
            {
                $exclusionFilter[] = $filter;
            }
        }

        if (!empty( $path ) )
        {
            return self::findRecursive( $path, array( '@\.php$@' ), $exclusionFilter, $this );
        }
        return false;
    }
322976
public function createQueryBuilderWithParentRoot($parent_id, $include_parent = true)
    {
        $query = $this->createQueryBuilder();
        return $this->alterQueryBuilderWithParentRoot($query, $parent_id, $include_parent);
    }
767639
protected function get(string $path, array $params = [], array $headers = [])
    {
        $response = $this->pureGet($path, $params, $headers);

        return ResponseMediator::getContent($response);
    }
336881
public function getResetPath($route, $extraParams = array())
    {
        $params = array(
            $this->getActionParameterName() => $this->getResetActionParameterName(),
            $this->getDatagridParameterName() => $this->getName(),
        );
        return $this->container->get('router')->generate($route, array_merge($params, $extraParams));
    }
1242343
private static function findRootDir($path, array $roots)
    {
        foreach ($roots as $root) {
            if (0 === strpos($path, $root)) {
                return $root;
            }
        }
    }
490733
public function uploadFile($path = '', $file = null, $extraHeaders = null)
    {
        if (file_exists($file['path'])) {
            $headers = [
                'Content-Length' => (string)$file['size']
            ];
            $finfo = finfo_open(FILEINFO_MIME);
            $mime = finfo_file($finfo, $file['path']);
            $parts = explode(";", $mime);
            $headers['Content-Type'] = $parts[0];
            $headers['Etag'] = md5_file($file['path']);
            $headers['Sha256'] = hash_file('sha256', $file['path']);
            $headers = isset($extraHeaders) ? array_merge($headers, $extraHeaders) : $headers;

            return $this->sendRequest(
                'PUT',
                $path . $file['name'],
                [
                    'headers' => $headers,
                    'body' => fopen($file['path'], 'rb'),
                    'expect' => true
                ]
            );
        }
    }
651119
public function children($path = "")
  {
    if ($path) {
      $parts = $this->split($path);
      $name = array_shift($parts);

      $children = array();
      if (isset($this->_subTrees[$name])) {
        $subtree = $this->_subTrees[$name];
        /* @var $subtree Wrapper_FS_Changes */
        $this->_appendChildren(
          $children, $name, $subtree->children($parts)
        );
      }
    } else {
      $children = $this->own();
      foreach ($this->_subTrees as $name => $subtree) {
        /* @var $subtree Wrapper_FS_Changes */
        $this->_appendChildren(
          $children, $name, $subtree->children()
        );
      }
    }

    return $children;
  }
1084112
public function getChildByPath($path)
    {
        if (!is_array($path)) {
            $path = trim($path, " /");
            $pieces = explode("/", $path);
        } else {
             $pieces = $path;
        }
            
        if (!sizeof($pieces)) return $this;

        if ($alias = array_shift($pieces)) {

                $c = $this->getChildByAlias($alias);
                if (sizeof($pieces)) {
                    return $c->getChildByPath($pieces);
                } else {
                    return $c;
                }

        }
        return $this;
    }
1090483
protected function _inpath($path, $parent) {
		return $path == $parent
			? true
			: in_array($parent, $this->getParents($path));
	}
1136132
public function findByName($name, $extraDatas = array(), $executeQuery = true)
    {
        $name  = strtoupper($name);
        /** @var \Doctrine\ORM\QueryBuilder $queryBuilder */
        $queryBuilder = $this->createQueryBuilder('resourceNode');
        $queryBuilder->where($queryBuilder->expr()->like('UPPER(resourceNode.name)', ':name'));

        if (0 < count($extraDatas)) {
            foreach ($extraDatas as $key => $extraData) {
                $queryBuilder
                    ->andWhere(sprintf('resourceNode.%s = :%s', $key, $key))
                    ->setParameter(sprintf(':%s', $key), $extraData);
            }
        }

        $queryBuilder
            ->orderBy('resourceNode.name', 'ASC')
            ->setParameter(':name', "%{$name}%");

        return $executeQuery ? $queryBuilder->getQuery()->getResult(): $queryBuilder;
    }
234289
public static function formatPath($pathOrPaths, ...$additionalPaths)
    {
        $path = rawurldecode(self::mergePaths($pathOrPaths, ...$additionalPaths));
        $path = self::removeSchemeFromUri($path, $scheme);

        // Remove self-referencing path parts (resolving already takes care of this)
        $replacements = 0;
        do {
            $path = str_replace(["/./", "//"], "/", $path, $replacements);
        } while ($replacements > 0);

        // Replace parent directory paths if possible
        $pathParts = explode("/", $path);

        $ignoredParts = 0;
        do {
            $parentKey = array_search("..", array_slice($pathParts, $ignoredParts, null, true));

            // Don't remove .. if it starts the path
            if ($parentKey > 0) {
                switch ($pathParts[$parentKey - 1]) {
                    // Don't remove root / but remove ..'s directly after it
                    case "":
                        unset($pathParts[$parentKey]);
                        break;

                    // Keep consecutive ..'s (only possible if the path starts with them)
                    case "..":
                        $ignoredParts++;
                        break;

                    // Collapse
                    default:
                        unset($pathParts[$parentKey - 1]);
                        unset($pathParts[$parentKey]);
                        break;
                }

                $pathParts = array_values($pathParts);
            } else {
                $ignoredParts++;
            }
        } while ($parentKey !== false);

        $path = implode("/", $pathParts);

        return $scheme . $path;
    }
1253053
public function getPathChild(array $path): NodeInterface
    {
        $child = $this;

        foreach ($path as $name) {
            $child = $child->getChild($name);
        }

        return $child;
    }
725168
public function alias($alias, $path = null)
	{
		if (is_null($path))
		{
			return $this->aliases[$alias] ?: null;
		}
		else
		{
			$this->aliases[$alias] = $path;
		}
	}
1035637
function &_extensions(&$root, $path = NULL, $create = false)
    {
        if (!isset($root)) {
            $root = $this->currentCert;
        }

        switch (true) {
            case !empty($path):
            case !is_array($root):
                break;
            case isset($root['tbsCertificate']):
                $path = 'tbsCertificate/extensions';
                break;
            case isset($root['tbsCertList']):
                $path = 'tbsCertList/crlExtensions';
                break;
        }

        $extensions = &$this->_subArray($root, $path, $create);

        if (!is_array($extensions)) {
            $false = false;
            return $false;
        }

        return $extensions;
    }