// Delete deletes an existing Elastigroup by ID.
771802
func (s *awsService) Delete(ctx context.Context, groupID string) error {
	input := &aws.DeleteGroupInput{
		GroupID: fi.String(groupID),
	}

	_, err := s.svc.Delete(ctx, input)
	return err
}
968798
func (r *Route) Delete(handlers ...Handler) *Route {
	return r.group.add("DELETE", r.path, handlers)
}
199375
func (api *API) Delete(images params.MetadataImageIds) (params.ErrorResults, error) {
	all := make([]params.ErrorResult, len(images.Ids))
	for i, imageId := range images.Ids {
		err := api.metadata.DeleteMetadata(imageId)
		all[i] = params.ErrorResult{common.ServerError(err)}
	}
	return params.ErrorResults{Results: all}, nil
}
334030
func (s *ChocolateStorage) Delete(id string) error {
	_, exists := s.chocolates[id]
	if !exists {
		return fmt.Errorf("Chocolate with id %s does not exist", id)
	}
	delete(s.chocolates, id)

	return nil
}
553181
func (set *StringSet) Delete(element string) bool {
	_, found := set.set[element]
	if found {
		delete(set.set, element)
	}
	return found
}
451283
func (agp *AuthGroupPermission) Delete(db XODB) error {
	var err error

	// if doesn't exist, bail
	if !agp._exists {
		return nil
	}

	// if deleted, bail
	if agp._deleted {
		return nil
	}

	// sql query
	const sqlstr = `DELETE FROM auth_group_permissions WHERE id = ?`

	// run query
	XOLog(sqlstr, agp.ID)
	_, err = db.Exec(sqlstr, agp.ID)
	if err != nil {
		return err
	}

	// set deleted
	agp._deleted = true

	return nil
}
703420
func (c *TagValueSeriesIDCache) delete(name, key, value []byte, x tsdb.SeriesID) {
	if mmap, ok := c.cache[string(name)]; ok {
		if tkmap, ok := mmap[string(key)]; ok {
			if ele, ok := tkmap[string(value)]; ok {
				if ss := ele.Value.(*seriesIDCacheElement).SeriesIDSet; ss != nil {
					ele.Value.(*seriesIDCacheElement).SeriesIDSet.Remove(x)
					c.tracker.IncDeletesHit()
					return
				}
			}
		}
	}
	c.tracker.IncDeletesMiss()
}
20536
func (l *LRUNoTS) Delete(key string) error {
	res, err := l.cache.Get(key)
	if err != nil && err != ErrNotFound {
		return err
	}

	// item already deleted
	if err == ErrNotFound {
		// surpress not found errors
		return nil
	}

	elem := res.(*list.Element)

	return l.removeElem(elem)
}
808861
func (col *Col) Delete(id int) error {
	col.db.schemaLock.RLock()
	part := col.parts[id%col.db.numParts]

	// Place lock, read back original document and delete document
	part.DataLock.Lock()
	originalB, err := part.Read(id)
	if err != nil {
		part.DataLock.Unlock()
		col.db.schemaLock.RUnlock()
		return err
	}
	err = part.Delete(id)
	part.DataLock.Unlock()
	if err != nil {
		col.db.schemaLock.RUnlock()
		return err
	}

	// Done with the collection data, next is to remove indexed values
	var original map[string]interface{}
	err = json.Unmarshal(originalB, &original)
	if err == nil {
		part.LockUpdate(id)
		col.unindexDoc(id, original)
		part.UnlockUpdate(id)
	} else {
		tdlog.Noticef("Will not attempt to unindex document %d during delete", id)
	}

	col.db.schemaLock.RUnlock()
	return nil
}
261153
func GroupDelete(ctx context.Context, groupName string) error {
	return groupServiceInstance.GroupDelete(ctx, groupName)
}
1211091
func (s *Store) Delete(ident Ident) (err error) {
	if err = ident.Validate(); err != nil {
		return
	}
	if ident.Variant != "" {
		return s.deleteVariant(ident)
	}
	return s.deleteItem(ident)
}
1131094
func (c *FakeGroups) Delete(name string, options *v1.DeleteOptions) error {
	_, err := c.Fake.
		Invokes(testing.NewRootDeleteAction(groupsResource, name), &user.Group{})
	return err
}
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
}
225480
func (r *router) DELETE(path string, handler Route) {
	r.group.DELETE(path, handler)
}
1124903
func (m *UserManager) Delete(id int64) error {
	stmt := Users.Delete().Where(Users.C("id").Equals(id))
	return m.conn.Query(stmt)
}
306216
func (x *Index) Delete(c context.Context, id string) error {
	req := &pb.DeleteDocumentRequest{
		Params: &pb.DeleteDocumentParams{
			DocId:     []string{id},
			IndexSpec: &x.spec,
		},
	}
	res := &pb.DeleteDocumentResponse{}
	if err := internal.Call(c, "search", "DeleteDocument", req, res); err != nil {
		return err
	}
	if len(res.Status) != 1 {
		return fmt.Errorf("search: internal error: wrong number of results (%d)", len(res.Status))
	}
	if s := res.Status[0]; s.GetCode() != pb.SearchServiceError_OK {
		return fmt.Errorf("search: %s: %s", s.GetCode(), s.GetErrorDetail())
	}
	return nil
}
63549
func (pdb *prefixDB) Delete(key []byte) {
	pdb.mtx.Lock()
	defer pdb.mtx.Unlock()

	pdb.db.Delete(pdb.prefixed(key))
}