def delete_repository(self, repository_id=None):
if repository_id is None:<EOL><INDENT>raise NullArgument()<EOL><DEDENT>if not isinstance(repository_id, Id):<EOL><INDENT>raise InvalidArgument('<STR_LIT>')<EOL><DEDENT>try:<EOL><INDENT>repository = RepositoryLookupSession(proxy=self._proxy,<EOL>runtime=self._runtime).get_repository(repository_id)<EOL><DEDENT>except Exception:<EOL><INDENT>raise<EOL><DEDENT>if repository._my_map['<STR_LIT>'] != '<STR_LIT>':<EOL><INDENT>raise PermissionDenied('<STR_LIT>')<EOL><DEDENT>url_path = construct_url('<STR_LIT>',<EOL>bank_id=repository_id)<EOL>result = self._delete_request(url_path)<EOL>return objects.Repository(result)<EOL>
Deletes a ``Repository``.

        :param repository_id: the ``Id`` of the ``Repository`` to remove
        :type repository_id: ``osid.id.Id``
        :raise: ``NotFound`` -- ``repository_id`` not found
        :raise: ``NullArgument`` -- ``repository_id`` is ``null``
        :raise: ``OperationFailed`` -- unable to complete request
        :raise: ``PermissionDenied`` -- authorization failure

        *compliance: mandatory -- This method must be implemented.*