Is Absolute Path?

@return boolean
436825
function isAbsolute()
    {
        $p = $this->getPath();

        reset($p);
        $fi = current($p);
        return $this->_isRoot($fi);
    }
488353
public static function isAbsolute($path)
    {
        if (empty($path)) {
            return false;
        }

        return $path[0] === '/' ||
            preg_match('/^[A-Z]:\\\\/i', $path) ||
            substr($path, 0, 2) === '\\\\' ||
            self::isRegisteredStreamWrapper($path);
    }
1048262
public function isAbsolutePathReference():bool{
		return $this->getScheme() === '' && $this->getAuthority() === '' && isset($this->getPath()[0]) && $this->getPath()[0] === '/';
	}
732190
public function checkPath($path)
    {
        $path = realpath($path);

        return ($path !== false && is_dir($path)) ? $path : false;
    }
67179
public static function path()
    {
        if (!self::isDebug()) {
            return false;
        }

        $result = array(
            'get_include_path' => explode(PATH_SEPARATOR, trim(get_include_path(), PATH_SEPARATOR)),
            '$_SERVER[PATH]'   => explode(PATH_SEPARATOR, trim($_SERVER['PATH'], PATH_SEPARATOR))
        );

        return self::i()->dump($result, '! paths !');
    }
739068
public function delete()
    {
        if ($this->isAbsolute()) {
            if ($this->isFile() || $this->isLink()) {
                // delete file and symlink
                return unlink($this->getPathname());
            } elseif ($this->isDir()) {
                // delete directory
                return rmdir($this->getPathname());
            }
            return false;
        } else {
            throw new FileException('Given file path is not a absolute path.');
        }
    }
76285
function abspath( $path = false ) {
		if ( ! $path )
			$path = ABSPATH;
		$folder = $this->find_folder( $path );

		// Perhaps the FTP folder is rooted at the WordPress install, Check for wp-includes folder in root, Could have some false positives, but rare.
		if ( ! $folder && $this->is_dir('/wp-includes') )
			$folder = '/';
		return $folder;
	}
660102
public static function isAbsolutePath($path): bool
    {
        return strspn($path, '/\\', 0, 1)
            || (strlen($path) > 3 && ctype_alpha($path[0])
                && ':' === $path[1]
                && strspn($path, '/\\', 2, 1)
            )
            || null !== parse_url($path, PHP_URL_SCHEME);
    }
839845
public function isAdminHome(): bool
    {
        return $this->url->current() == $this->url->to($this->config->get('helpers.paths.admin'));
    }
857385
public function isValidLocalPath()
    {
        //====================================================================//
        // Verify no result in Cache
        if (!isset($this->ValidLocalPath)) {
            $path = Splash::getLocalPath();
            //====================================================================//
            // Verify Local Path Exist
            if (is_null($path) || !is_dir($path)) {
                $this->ValidLocalPath = false;

                return Splash::log()->err(Splash::trans('ErrLocalPath', (string) $path));
            }

            $this->ValidLocalPath = true;
        }

        return $this->ValidLocalPath;
    }
1133107
public function setPathAbsolute(string $path_absolute) {
        if(!$this->setModified('path_absolute', $path_absolute)->isModified()) {
            return $this;
        }
		$this->path_absolute = $path_absolute;
		return $this;
    }
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;
    }
680837
public function have_pakefile()
    {
        $is_windows = (strtolower(substr(PHP_OS, 0, 3)) == 'win');

        $here = getcwd();
        foreach ($this->PAKEFILES as $file) {
            $path_includes_directory = basename($file) !== $file;

            if ($path_includes_directory) {
                if ($is_windows) {
                    $is_absolute_path = ($file[0] == '\\' or $file[0] == '/' or mb_ereg('^[A-Za-z]+:', $file) === 1);
                } else {
                    $is_absolute_path = $file[0] == '/';
                }
            } else {
                $is_absolute_path = false;
            }

            if ($is_absolute_path) {
                $filepath = $file;
            } else {
                $filepath = $here . DIRECTORY_SEPARATOR . $file;
            }

            if (file_exists($filepath)) {
                $this->pakefile = realpath($filepath);
                return true;
            }
        }

        return false;
    }
551735
static function isAbsolute($path)
    {
        if (realpath($path) === $path) {
            return true;
        }

        if (empty($path)) {
            return false;
        }

        # Absolute Path (Unix) or Absolute UNC Path.
        if ($path[0] === '/' or $path[0] === '\\') {
            return true;
        }

        # If the path starts with a drive letter or "\\" (Windows):
        if (static::isWindows() and preg_match('#^([a-z]\:)?\\\\{1,2}#i', $path)) {
            return true;
        }
        return false;
    }
586132
def _path_is_abs(path):
    '''
    
    '''
    if path is None:
        return True
    try:
        return os.path.isabs(path)
    except AttributeError:
        # Non-string data passed
        return False
628774
function logicalPath($absolutePath)
    {
        foreach ($this->loadPaths->paths() as $lp) {
            $absoluteLoadPath = realpath($lp);

            if (strpos($absolutePath, $absoluteLoadPath) === 0) {
                return ltrim(substr($absolutePath, strlen($absoluteLoadPath)), '/');
            }
        }
    }
392178
public function exists(): bool
    {
        $realPath = \realpath($this->path);
        if (false === $realPath) {
            return false;
        }
        $this->path = $realPath;
        $this->assertCorrectType();

        return true;
    }