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.');
        }
    }