src/Samurai/Component/FileSystem/File.php
public function absolutize()
    {
        $new = [];
        $path = $this->path;
        if ($path[0] !== '/') $path = $this->cwd . DS . $this->path;
        $paths = explode(DS, $path);
        foreach ($paths as $p) {
            switch ($p) {
                case '.':
                    break;
                case '..':
                    array_pop($new);
                    if (!$new) $new[] = '';
                    break;
                default:
                    $new[] = $p;
                    break;
            }
        }
        $this->path = join(DS, $new);
    }
public function absolutize()
    {
        $new = [];
        $path = $this->path;
        if ($path[0] !== '/') $path = $this->cwd . DS . $this->path;
        $paths = explode(DS, $path);
        foreach ($paths as $p) {
            switch ($p) {
                case '.':
                    break;
                case '..':
                    array_pop($new);
                    if (!$new) $new[] = '';
                    break;
                default:
                    $new[] = $p;
                    break;
            }
        }
        $this->path = join(DS, $new);
    }
public function absolutize ( ) { $ new = [ ] ; $ path = $ this -> path ; if ( $ path [ 0 ] !== '/' ) $ path = $ this -> cwd . DS . $ this -> path ; $ paths = explode ( DS , $ path ) ; foreach ( $ paths as $ p ) { switch ( $ p ) { case '.' : break ; case '..' : array_pop ( $ new ) ; if ( ! $ new ) $ new [ ] = '' ; break ; default : $ new [ ] = $ p ; break ; } } $ this -> path = join ( DS , $ new ) ; }
relational path to absolute path.

@access  public
relational path to absolute path .