// Delete removes an item by ID
4544
func (db *memDB) Delete(c *Container) error {
	return db.withTxn(func(txn *memdb.Txn) error {
		view := &memdbView{txn: txn}
		names := view.getNames(c.ID)

		for _, name := range names {
			txn.Delete(memdbNamesTable, nameAssociation{name: name})
		}

		// Ignore error - the container may not actually exist in the
		// db, but we still need to clean up associated names.
		txn.Delete(memdbContainersTable, NewBaseContainer(c.ID, c.Root))
		return nil
	})
}
84459
func (rw *GCS) Delete(id string) error {
	ctx := context.Background()
	obj := rw.bucket.Object(rw.Prefixed.Name(id))
	return obj.Delete(ctx)
}
1244502
func (idx *TruncIndex) Delete(id string) error {
	idx.Lock()
	defer idx.Unlock()
	if _, exists := idx.ids[id]; !exists || id == "" {
		return fmt.Errorf("no such id: '%s'", id)
	}
	delete(idx.ids, id)
	if deleted := idx.trie.Delete(patricia.Prefix(id)); !deleted {
		return fmt.Errorf("no such id: '%s'", id)
	}
	return nil
}
1003597
func (s *MemoryStore) Delete(key string) error {
	s.mu.Lock()
	defer s.mu.Unlock()
	delete(s.data, key)
	return nil
}
1243373
func (c *Client) Delete() *Request {
	req := c.Request()
	req.Method("DELETE")
	return req
}
587745
func (c *Client) Delete(key string) error {
	return c.deleteRecurse(key, false)
}
821649
func (self *DocumentBase) Delete() error {

	if self.Id.Valid() {

		self.SetDeleted(true)

		return self.Save()
	}

	return errors.New("Invalid object id")
}
1021320
func (c *Collection) Delete(i gtreap.Item) {
	c.assertNotReadOnly()

	c.rootLock.Lock()
	c.root = c.root.Delete(i)
	c.rootLock.Unlock()
}
1218182
func (s Int32) Delete(items ...int32) {
	for _, item := range items {
		delete(s, item)
	}
}
881366
func (self *InvoiceItemClient) Delete(id string) (bool, error) {
	resp := DeleteResp{}
	path := "/v1/invoiceitems/" + url.QueryEscape(id)
	if err := query("DELETE", path, nil, &resp); err != nil {
		return false, err
	}
	return resp.Deleted, nil
}
487586
func (r *GormQueryRepository) Delete(ctx context.Context, ID uuid.UUID) error {
	defer goa.MeasureSince([]string{"goa", "db", "query", "delete"}, time.Now())
	q := Query{ID: ID}
	tx := r.db.Delete(q)

	if err := tx.Error; err != nil {
		log.Error(ctx, map[string]interface{}{
			"query_id": ID.String(),
		}, "unable to delete the query")
		return errors.NewInternalError(ctx, err)
	}
	if tx.RowsAffected == 0 {
		log.Error(ctx, map[string]interface{}{
			"query_id": ID.String(),
		}, "no row was affected by the delete operation")
		return errors.NewNotFoundError("query", ID.String())
	}
	return nil
}
176062
func (s *SecretService) Delete(itemPath dbus.ObjectPath) error {
	var prompt dbus.ObjectPath
	err := s.Object(serviceName, itemPath).Call(itemInterface+".Delete", 0).Store(&prompt)
	if err != nil {
		return err
	}

	_, _, err = s.handlePrompt(prompt)
	if err != nil {
		return err
	}

	return nil
}
614738
func (this *MemoryStore) Delete(id string) error {
	this.l.Lock()
	defer this.l.Unlock()
	delete(this.m, id)
	return nil
}
630037
func (mem *memNamedMapping) Delete(name string) (value interface{}, found bool) {
	item, found := mem.removeNameIdxSync(name)
	if found {
		mem.publishDelToChannel(name, item.value)
		return item.value, found
	}
	return nil, false
}
695591
func (s String) Delete(items ...string) {
	for _, item := range items {
		delete(s, item)
	}
}
853779
func (m *Manager) Delete(contractid string) (err error) {
	_, err = m.collection.RemoveAll(bson.M{"contractid": contractid})
	return
}
648141
func (db *DB) Delete(key []byte, wo *opt.WriteOptions) error {
	return db.putRec(keyTypeDel, key, nil, wo)
}