MCPcopy Create free account
hub / github.com/plexdrive/plexdrive / fetch

Method fetch

chunk/storage.go:407–415  ·  view source on GitHub ↗

fetch chunk and index by id

(id RequestID)

Source from the content-addressed store, hash-verified

405
406// fetch chunk and index by id
407func (s *Storage) fetch(id RequestID) *Chunk {
408 index, exists := s.chunks[id]
409 if !exists {
410 return nil
411 }
412 chunk := s.buffers[index]
413 s.stack.Touch(chunk.item)
414 return chunk
415}

Callers 2

LoadMethod · 0.95
StoreMethod · 0.95

Calls 1

TouchMethod · 0.80

Tested by

no test coverage detected