// Remove takes the key out of all buckets. If value is non-nil, the key will only be removed if it has
// the same value. Returns true if the key was removed.
350956
func (s *scheduler) Remove(key, value interface{}) bool {
	s.mu.Lock()
	defer s.mu.Unlock()

	match := true
	for _, bucket := range s.buckets {
		if value != nil {
			if old, ok := bucket[key]; ok && old != value {
				match = false
				continue
			}
		}
		delete(bucket, key)
	}
	return match
}
73516
func (c *TwoQueueCache) Remove(key interface{}) {
	c.lock.Lock()
	defer c.lock.Unlock()
	if c.frequent.Remove(key) {
		return
	}
	if c.recent.Remove(key) {
		return
	}
	if c.recentEvict.Remove(key) {
		return
	}
}
46468
func (c *keyStringValueChanger) Remove() error {
	if c.err != nil {
		return c.err
	}
	return c.node.remove()
}
641867
func (m *MultiMap) Remove(key interface{}, value interface{}) {
	values, found := m.m[key]
	if found {
		for i, v := range values {
			if v == value {
				m.m[key] = append(values[:i], values[i+1:]...)
			}
		}
	}
	if len(m.m[key]) == 0 {
		delete(m.m, key)
	}
}
493648
func (l *List) Remove() error {
	err := (*bbolt.DB)(l.db).Update(func(tx *bbolt.Tx) error {
		return tx.DeleteBucket(l.name)
	})
	// Mark as removed by setting the name to nil
	l.name = nil
	return err
}
631173
func (p *partition) remove(key []byte) {
	p.mu.Lock()
	delete(p.store, string(key))
	p.mu.Unlock()
}
951572
func (m *SecureMap) Remove(key interface{}) {
	m.lock.Lock()
	delete(m.data, key)
	m.lock.Unlock()
}
485036
func (s *shard) Remove(key uint32) {
	s.Lock()
	delete(s.items, key)
	s.Unlock()
}
523294
func (s *set) Remove(vs ...interface{}) {
	for _, v := range vs {
		delete(s.values, v)
	}
}
238054
func (b *UpdateBuilder) Remove(column string) *UpdateBuilder {
	return b.removeValue(column, param(column))
}
1001838
func (l *Lambda) remove(kind, name string, m map[string]interface{}) {
	l.log(kind, name, m, '-', red)
}
817322
func (b *Bucket) Delete(key []byte) error {
	err := b.bucket.Delete(key)
	if err == bolt.ErrTxNotWritable {
		return kv.ErrTxNotWritable
	}
	return err
}
629766
func (c *Client) Remove(name string) error {
	return delete(c, name, false)
}
927080
func (rh *HashMap) Remove() error {
	conn := rh.pool.Get(rh.dbindex)
	// Find all hashmap keys that starts with rh.id+":"
	results, err := redis.Values(conn.Do("KEYS", rh.id+":*"))
	if err != nil {
		return err
	}
	// For each key id
	for i := 0; i < len(results); i++ {
		// Delete this key
		if _, err = conn.Do("DEL", getString(results, i)); err != nil {
			return err
		}
	}
	return nil
}
906494
func (n *NodeLabels) Remove(key string) (removed bool, err error) {
	if isInternalLabel(key) {
		return false, ErrLabelInternalKey
	}
	return n.node.memberlist.RemoveLocalLabels(key), nil
}
530682
func (c *Config) Remove(key string) (value interface{}, ok bool) {
	return c.values.Remove(c.NewKey(key))
}
1250171
func (b *Bucket) Delete(key []byte) error {
	_ = b.btree.Delete(&item{key: key})
	return nil
}