@param null|string $path

@return string|null
962814
public function svg( $path = null )
	{
		if( file_exists( $this->imagePath( $path ))) {
			return file_get_contents( $this->imagePath( $path ));
		}
	}
1059127
private function filterPath(?string $path): string
    {
        if (null === $path) {
            throw new SyntaxError('The path can not be null');
        }

        if ('' === $path || ',' === $path) {
            return 'text/plain;charset=us-ascii,';
        }

        if (1 === preg_match(self::REGEXP_DATAPATH, $path)) {
            $path = substr($path, 0, -1).'charset=us-ascii,';
        }

        if (1 === preg_match(self::REGEXP_NON_ASCII_PATTERN, $path) && false === strpos($path, ',')) {
            throw new SyntaxError(sprintf('The path `%s` is invalid according to RFC2937', $path));
        }

        return $path;
    }
711102
public function getNode($path)
    {
        $nodes = $this->getNodes($path);
        if ($nodes && ($nodes->length > 0)) {
            return $nodes->item(0);
        }

        return null;
    }
585277
public function get($path) {
		if (!$this->zookeeper->exists($path)) {
			return null;
		}
		return $this->zookeeper->get($path);
	}
199620
public function get($path = null)
    {
        if ($path === null) {
            return $this->data;
        }

        $keys = explode('/', $path);
        $data = $this->data;
        foreach ($keys as $key) {
            if (is_array($data) && array_key_exists($key, $data)) {
                $data = $data[$key];
            } else {
                return null;
            }
        }

        return $data;
    }
1203599
public function url($path = null)
    {
        if ($this->isEmptyPath($path)) {
            return $this->getBaseUrl();
        }
        if ($this->containsScheme($path)) {
            return $path;
        }

        $baseUrl = $this->getBaseUrl();

        return $this->getBaseUrl().($baseUrl == '/' ? '' : '/').trim($path, '/');
    }
725168
public function alias($alias, $path = null)
	{
		if (is_null($path))
		{
			return $this->aliases[$alias] ?: null;
		}
		else
		{
			$this->aliases[$alias] = $path;
		}
	}
748794
protected function _prepareFilePath($path = null) {
		if (empty($path)) {
			return false;
		}

		if (DIRECTORY_SEPARATOR !== '\\') {
			return $path;
		}

		$path = str_replace('\\', '/', $path);

		return $path;
	}
1207388
public function url(string $path = null): string
    {
        return $path ? sv_url($path) : sv_url()->current();
    }
1367092
public function path($path, $query = null)
    {
        $uri = $this->request()->getUri();
        $uri = $uri->withPath($path);
        if ($query) {
            $uri = $uri->withQuery($query);
        }
        return (string) $uri;
    }
389216
protected function cleanPathInternal($path)
    {
        if ($this->isVirtual($path)) {
            return $this->cleanPath($path);
        }

        if ($this->hasCDBack($path)) {
            $realpath = $this->cleanPath(realpath($path));
            return $realpath ?: null;
        }

        return $this->cleanPath($path);
    }
1338682
public static function loadByPath($path)
    {
        $path = trim($path, '/');
        if (!$path) {
            return self::loadRoot();
        }

        $info = pathinfo($path);
        $nodes = self::loadByName($info['basename']);
        if (empty($nodes)) {
            return null;
        }

        foreach ($nodes as $node) {
            if ($node->getPath() === $path) {
                return $node;
            }
        }

        return null;
    }
40818
private function loadFile($path)
    {
        if (file_exists($path)) {
            return $this->loadJsonFile($path);
        }

        $dirs = $this->paths();
        if (empty($dirs)) {
            return null;
        }

        $data = [];
        $dirs = array_reverse($dirs);
        foreach ($dirs as $dir) {
            $file = $dir.DIRECTORY_SEPARATOR.$path;
            if (file_exists($file)) {
                $data = array_replace_recursive($data, $this->loadJsonFile($file));
            }
        }

        if (empty($data)) {
            return null;
        }

        return $data;
    }
1237465
protected function getContent(string $path): ?vfsStreamContent
    {
        if (null === self::$root) {
            return null;
        }

        if (self::$root->getName() === $path) {
            return self::$root;
        }

        if ($this->isInRoot($path) && self::$root->hasChild($path) === true) {
            return self::$root->getChild($path);
        }

        return null;
    }
667548
public function url($path = null)
    {
        if ($path === null) {
            $path = $this->path;
        }

        return $this->base_path . $path;
    }
1051421
public function base($path = null)
    {
        return ($this->baseUrl ? rtrim($this->baseUrl, '/' ).'/' : '/').($path ? trim($path, '/') : '');
    }
845777
public function init($path = null)
    {
        $this->clearAll();
        $this->addCommandName(sprintf('%s %s', self::SUBMODULE_COMMAND, self::SUBMODULE_INIT_COMMAND));
        if (null !== $path) {
            $this->addPath($path);
        }

        return $this->getCommand();
    }