MCPcopy Create free account
hub / github.com/allegro/bigcache / Peek

Method Peek

queue/bytes_queue.go:186–189  ·  view source on GitHub ↗

Peek reads the oldest entry from list without moving head pointer

()

Source from the content-addressed store, hash-verified

184
185// Peek reads the oldest entry from list without moving head pointer
186func (q *BytesQueue) Peek() ([]byte, error) {
187 data, _, err := q.peek(q.head)
188 return data, err
189}
190
191// Get reads entry from index
192func (q *BytesQueue) Get(index int) ([]byte, error) {

Callers 7

TestPeekFunction · 0.95
TestResetFunction · 0.95
setMethod · 0.80
addNewWithoutLockMethod · 0.80
cleanUpMethod · 0.80

Calls 1

peekMethod · 0.95

Tested by 3

TestPeekFunction · 0.76
TestResetFunction · 0.76