Delete removes the item with the given id, if present.
(id string)
| 62 | |
| 63 | // Delete removes the item with the given id, if present. |
| 64 | func (t *Tracker[T]) Delete(id string) { |
| 65 | t.mu.Lock() |
| 66 | delete(t.items, id) |
| 67 | t.mu.Unlock() |
| 68 | } |
| 69 | |
| 70 | // Clear removes all tracked items and returns a snapshot of the previous contents. |
| 71 | // |
no outgoing calls