// Clear will remove all the tokens. Call after a permission change.
483707
func Clear(w http.ResponseWriter, r *http.Request, sess *sessions.Session) {
	// Delete the map if it doesn't exist
	if _, ok := sess.Values[TokenName]; ok {
		delete(sess.Values, TokenName)
		sess.Save(r, w)
	}
}
402695
func (l *Loader) Clear(ctx context.Context, key Key) Interface {
	l.cacheLock.Lock()
	l.cache.Delete(ctx, key)
	l.cacheLock.Unlock()
	return l
}
1346357
func (m *SecureMap) Clear() {
	m.lock.Lock()
	m.data = make(map[interface{}]interface{})
	m.lock.Unlock()
}
998948
func (fds *FDSet) Clear(fd uintptr) {
	fds.X__fds_bits[fd/NFDBITS] &^= (1 << (fd % NFDBITS))
}
1206704
func (b *Buffer) Clear() {
	b.rw.Lock()
	{
		b.buffer = nil
	}
	b.rw.Unlock()
}
336802
func (db *Database) Clear(sid string) {
	keys := db.keys(sid)
	for _, key := range keys {
		db.redis.Delete(key)
	}
}
769653
func (this *RedisStore) Clear() error {
	vals, err := this.getSessionKeys()
	if err != nil {
		return err
	}
	if len(vals) > 0 {
		this.conn.Send("MULTI")
		for _, v := range vals {
			this.conn.Send("DEL", v)
		}
		_, err = this.conn.Do("EXEC")
		if err != nil {
			return err
		}
	}
	return nil
}
278851
func Clear(req *http.Request) {
	crc := getContextReadCloser(req).(*contextReadCloser)
	crc.context = map[interface{}]interface{}{}
}
1367867
func (b *Batch) Clear() {
	b.cont.Triangles.SetLen(0)
	b.cont.Dirty()
}
1058981
func Clear(ctx context.Context, checksum string, force bool) error {
	if clipboard.Unsupported {
		return ErrNotSupported
	}

	cur, err := clipboard.ReadAll()
	if err != nil {
		return errors.Wrapf(err, "failed to read clipboard: %s", err)
	}

	hash := fmt.Sprintf("%x", sha256.Sum256([]byte(cur)))
	if hash != checksum && !force {
		return nil
	}

	if err := clipboard.WriteAll(""); err != nil {
		_ = notify.Notify(ctx, "gopass - clipboard", "Failed to clear clipboard")
		return errors.Wrapf(err, "failed to write clipboard: %s", err)
	}

	if err := clearClipboardHistory(ctx); err != nil {
		_ = notify.Notify(ctx, "gopass - clipboard", "Failed to clear clipboard history")
		return errors.Wrapf(err, "failed to clear clipboard history: %s", err)
	}

	if err := notify.Notify(ctx, "gopass -clipboard", "Clipboard has been cleared"); err != nil {
		return errors.Wrapf(err, "failed to send unclip notification: %s", err)
	}

	return nil
}
634842
func (c *Ctrie) Clear() {
	for {
		root := c.readRoot()
		gen := &generation{}
		newRoot := &iNode{
			main: &mainNode{cNode: &cNode{array: make([]branch, 0), gen: gen}},
			gen:  gen,
		}
		if c.rdcssRoot(root, gcasRead(root, c), newRoot) {
			return
		}
	}
}
421574
func (h *History) Clear() {
	h.tmp = make([]string, len(h.histories))
	for i := range h.histories {
		h.tmp[i] = h.histories[i]
	}
	h.tmp = append(h.tmp, "")
	h.selected = len(h.tmp) - 1
}
1319029
func (tm *tokenManager) clear() {
	for _ = range time.Tick(time.Minute * 3) {
		keys := make([]interface{}, 0, 100)

		for item := range tm.Iter() {
			if time.Now().Sub(item.val.(token).createTime) > tm.expiredAfter {
				keys = append(keys, item.key)
			}
		}

		tm.DeleteMulti(keys)
	}
}
1236190
func (r *RegionSet) Clear() {
	r.lock.Lock()
	defer r.lock.Unlock()
	r.regions = r.regions[0:0]
	r.flush()
}
805258
func (renderer *Renderer) Clear() error {
	return errorFromInt(int(
		C.SDL_RenderClear(renderer.cptr())))
}
1119883
func (s *VppDriverOperState) Clear() error {
	key := fmt.Sprintf(vppOperPath, s.ID)
	return s.StateDriver.ClearState(key)
}
1084246
func (s *FeatureFlagSet) Clear() {
	s.Lock()
	defer s.Unlock()
	s.features = make(map[Feature]*featureSlot)
}