Get the path to the file from the root of the documentation

@return string
353055
public function getRelativePath()
    {
        $root = $this;
        while ($root->getParent() != null) {
            $root = $root->getParent();
        }

        return substr($this->path, strlen($root->getPath()) + 1);
    }
1327816
public static function getProjectRootPath()
    {
        $projectRootPath = '';

        $fileName = 'composer.json';
        $directoryPath = __DIR__;

        // Path of directory it's not the path of last directory?
        while (DIRECTORY_SEPARATOR !== $directoryPath) {
            $filePath = static::concatenatePaths($directoryPath, $fileName);

            /*
             * Is here file we are looking for?
             * Maybe it's a project's root path
             */
            if (file_exists($filePath)) {
                $projectRootPath = $directoryPath;
            }

            $directoryPath = dirname($directoryPath);
        }

        return $projectRootPath;
    }
1012741
public function getDocumentation()
    {
        $documentation = null;
        $documentationNodes = $this->element->getElementsByTagName('documentation');
        if ($documentationNodes->length > 0) {
            $documentation = $documentationNodes->item(0)->nodeValue;
        }
        return $documentation;
    }
319633
public function getRelativePath()
    {
        // Root module
        $parent = $this->module->getRelativePath();
        if (!$parent) {
            return $this->relativePath;
        }
        return Path::join($parent, $this->relativePath);
    }
329933
private function getFilePath()
    {

        $tmpDir = realpath($this->getContainer()->get('kernel')->getRootDir() . '/../var/tmp/');
        $fileName = '/' . str_replace(':', '--', $this->getName()) . '.sock';

        if (!file_exists($tmpDir)) {
            mkdir($tmpDir);
        }

        return $tmpDir . $fileName;
    }
702354
public function getDestinationFilePath()
    {
        $path = $this->laravel['modules']->getModulePath($this->getModuleName());

        $controllerPath = $this->laravel['modules']->config('paths.generator.controller');

        return $path.$controllerPath.'/'.$this->getControllerName().'.php';
    }
611256
protected function _getFilePath()
    {
        $opt_directory = $this->getDirPath();
        $file = $opt_directory . DIRECTORY_SEPARATOR . $this->getRealm() . '.array.php';

        return $file;
    }
1044844
public function getRootPath()
    {
        if (null === $this->rootPath) {
            $this->rootPath = dirname((new \ReflectionClass($this))->getFileName());
        }

        return $this->rootPath;
    }
78639
private function getFilePath()
    {
        $fullname = $this->fullName;
        $rootPath = Yii::getAlias('@webroot');

        if (substr($fullname, 0, 1) != '/') {
            $fullname = '/' . $fullname;
        }

        return $rootPath . $fullname;
    }
561032
public function getViewPath(): string
    {
        if (is_file($this->tplDistPath)) {
            if ($this->disableTplCache) {
                $this->buildViewTemplate();
            }
        } else {
            $this->buildViewTemplate();
        }
        return $this->tplDistPath;
    }
670790
public function getBasePath(): string
	{
		if($this->basePath === null)
		{
			$path = $this->server->get('SCRIPT_NAME');

			$this->basePath = rtrim(str_replace(basename($path), '', $path), '/');
		}

		return $this->basePath;
	}
902136
public function getPath()
    {
        if ($this->file !== null) {
            return $this->file->getForLocalProcessing(false);
        } else {
            return $this->fileInfo['path'];
        }
    }
564919
public function getRelativePath()
    {
        if ($this->file !== null) {
            return dirname($this->file->getForLocalProcessing(false)) . '/';
        } else {
            return str_replace(PATH_site, '', $this->fileInfo['path']);
        }
    }
825132
private function _get_path()
    {

        if (empty($this->file) && is_string($this->file)) return false;

        if (strpos($this->file, '/') !== false) {
            $path = explode('/', $this->file);
            array_pop($path);
            $this->path = (string)implode('/', $path) . '/';
        } elseif (strpos('\\', $this->file) !== false) {
            $path = explode('\\', $this->file);
            array_pop($path);
            $this->path = (string)implode('\\', $path) . '\\';
        } else {
            $this->path = getcwd() . '/';
        }

        return true;
    }
619227
private function getFilePath()
    {
        $fullname = $this->fullName;
        $rootPath = yii::getAlias('@uploads/article/ueditor');

        if (substr($fullname, 0, 1) != '/') {
            $fullname = '/' . $fullname;
        }

        return $rootPath . $fullname;
    }
638074
public function getBaseStaticPath() {
		if ($this->staticBasePath === null) {
			if (isset($_SERVER['DOCUMENT_ROOT'])) {
				$this->staticBasePath = $_SERVER['DOCUMENT_ROOT'];
			} else {
				$this->staticBasePath = realpath('.');
			}
		}
		
		return $this->staticBasePath;
	}
258728
public function getRootPath()
  {
    $folder = WebApp::getPageFolder() . $this->code;
    if (StringTools::right($folder, 1) != '/') {
      $folder .= '/';
    }
    return $folder;
  }