def deleteResource(self, pid):
url = "<STR_LIT>".format(url_base=self.url_base,<EOL>pid=pid)<EOL>r = self._request('<STR_LIT>', url)<EOL>if r.status_code != <NUM_LIT:200>:<EOL><INDENT>if r.status_code == <NUM_LIT>:<EOL><INDENT>raise HydroShareNotAuthorized(('<STR_LIT>', url))<EOL><DEDENT>elif r.status_code == <NUM_LIT>:<EOL><INDENT>raise HydroShareNotFound((pid,))<EOL><DEDENT>else:<EOL><INDENT>raise HydroShareHTTPException((url, '<STR_LIT>', r.status_code))<EOL><DEDENT><DEDENT>resource = r.json()<EOL>assert(resource['<STR_LIT>'] == pid)<EOL>return resource['<STR_LIT>']<EOL>
Delete a resource.

:param pid: The HydroShare ID of the resource