Delete a single item with the given ID
387
def delete(self, id):
        ''''''
        if not self._item_path:
            raise AttributeError('delete is not available for %s' % self._item_name)
        target = self._item_path % id
        self._redmine.delete(target)
        return None
398129
def deleteItem(self, itemID):
        
        collections = self.get_data_collections()

        query = {"currentMax": {"$exists": True}}
        currentMax = self.noteDB["IDs"].find_one(query)['currentMax']
        query = {"unusedIDs": {"$exists": True}}
        unusedIDs = self.noteDB['IDs'].find_one(query)['unusedIDs']

        if (itemID > currentMax) or (itemID in unusedIDs):
            raise ValueError("ID {0} does not exist".format(itemID))

        # Find document with ID
        for coll in collections:
            self.noteDB[coll].remove({"ID": itemID})

        if currentMax == itemID:
            self.noteDB['IDs'].update({"currentMax": currentMax},
                                      {"currentMax": currentMax - 1})
        else:
            unusedIDs.append(itemID)
            self.noteDB['IDs'].update({"unusedIDs": {"$exists": True}},
                                      {"unusedIDs": unusedIDs})

        return itemID
1021535
def delete(id, options={})
      request :delete, id, options
    rescue Stretcher::RequestError => e
      raise e if e.http_response.status != 404
      false
    end
810531
def delete(self, id):
        
        path = partial(_path, self.adapter)
        path = path(id)
        return self._delete(path)
659969
def delete(self, request, _id):
        
        _id = deserialize(_id)

        to_delete = self.collection.get({'_id': _id})
        if to_delete:
            deleted = to_delete.delete()

            return Response(
                response=serialize(deleted),
                status=(
                    200 if not all(
                        key in deleted for key in [
                            'error_code', 'error_type', 'error_message'
                        ]
                    ) else 400
                )
            )
        else:
            return Response(
                response=serialize(
                    DocumentNotFoundError(self.collection.__name__, _id)
                ),
                status=404
            )
338042
def destroy(self, id):
        
        path = '{}/destroy'.format(id)
        url = utils.urljoin(self.url, path)
        response = self.session.post(url)
        return response.ok
371839
def dynamic_content_item_delete(self, id, **kwargs):
        ""
        api_path = "/api/v2/dynamic_content/items/{id}.json"
        api_path = api_path.format(id=id)
        return self.call(api_path, method="DELETE", **kwargs)
880006
def delete(self, id):
        """"""
        run = self.backend_store.get_run(id)
        if not run:
            return abort(http_client.NOT_FOUND,
                         message="Run {} doesn't exist".format(id))
        if not self.manager.delete_run(run):
            return abort(http_client.BAD_REQUEST,
                         message="Failed to find the task queue "
                                 "manager of run {}.".format(id))
        return '', http_client.NO_CONTENT
1137825
public void deleteById(Object id) {

        int count = beginDelete().whereEquals(idColumn.getColumnName(), id).delete();

        if (count == 0) {
            throw new RowNotFoundException(table, id);
        }
    }
1176691
public void remove(Id id){
        String dir = getBaseDirectory(id.getDatabase(),id.getCollection());
        boolean i1 = new File(dir+File.separator+id.getEntity()).delete();
        boolean i2 = new File(dir+File.separator+id.getEntity()+".json").delete();
        if(LOG.isDebugEnabled())
            LOG.debug("File removed successfully("+(i1&&i2)+") id: "+id);
    }
614086
public final synchronized void removeId(long id)
	{
		if (tc.isEntryEnabled()) Tr.entry(tc, "removeId", new Long(id));

		_idMap.remove(id);

		if (tc.isEntryEnabled()) Tr.exit(tc, "removeId");
	}
476634
def delete(self, object_id):
        
        obj = self.session.query(self.cls).filter_by(id=object_id).one()
        self.session.delete(obj)
        return obj
1180952
public function delete($id = null)
    {
        // If an ID is passed to the method, we will set the where clause to check
        // the ID to allow developers to simply and quickly remove a single item
        // without manually specifying the where clauses.
        if (! is_null($id)) {
            $this->where('id', '=', $id);
        }

        return $this->processor->processDeleteRequest($this, $this->runRequest());
    }
240755
function remove(id) {
                    var i;
                    for (i = 0; i < $scope.alerts.length; i += 1) {
                        if ($scope.alerts[i].id === id) {
                            $scope.alerts.splice(i, 1);
                            return;
                        }
                    }
                }
876205
function(id, callback) {
    
    var self = this;
    
    if (typeof id == 'number' || id instanceof Array) {
      
      // Remove entry from database
      this.driver.deleteById({
        id: id,
        table: this.context
      }, function(err, results) {
        callback.call(self, err);
      });

    } else if (id && typeof id == 'object') {
      
      var o = id;
      
      this.driver.deleteWhere({
        condition: _.keys(o).join('=? AND ') + '=?',
        params: _.values(o),
        table: this.context
      }, function(err, results) {
        callback.call(self, err);
      });
      
    } else {
      
      callback.call(self, new Error(util.format("%s: Wrong value for `id` parameter", this.className)));
      
    }

  }
906554
def delete(self, item, dry_run=None):
        """"""
        return self.backend.delete(item, dry_run=dry_run)
613081
function remove ( $id = null, $dumb = null )
    {
        eZPersistentObject::removeObject( eZDiscountSubRule::definition(),
                                          array( "id" => $id ) );
    }