function setDir($dir) { if ($this->isReference()) { throw $this->tooManyAttributes(); } if ($dir instanceof PhingFile) { $dir = $dir->getPath(); } $this->dir = new PhingFile((string) $dir); }