public function setRoot($dir)
    {
        if (!is_dir($dir)) {
            throw new Exception(sprintf('Not found directory: %s', $dir));
        }

        $this->root = $this->cleanPath($dir);
    }
public function setRoot($dir)
    {
        if (!is_dir($dir)) {
            throw new Exception(sprintf('Not found directory: %s', $dir));
        }

        $this->root = $this->cleanPath($dir);
    }
public function setRoot ( $ dir ) { if ( ! is_dir ( $ dir ) ) { throw new Exception ( sprintf ( 'Not found directory: %s' , $ dir ) ) ; } $ this -> root = $ this -> cleanPath ( $ dir ) ; }
Setup root directory.

@param string $dir
@throws Exception
Setup root directory .