MCPcopy
hub / github.com/kopia/kopia / inMemoryCache

Struct inMemoryCache

repo/format/format_blob_cache.go:49–57  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

47}
48
49type inMemoryCache struct {
50 timeNow func() time.Time // +checklocksignore
51
52 mu sync.Mutex
53 // +checklocks:mu
54 data map[blob.ID][]byte
55 // +checklocks:mu
56 times map[blob.ID]time.Time
57}
58
59func (c *inMemoryCache) Get(_ context.Context, blobID blob.ID) ([]byte, time.Time, bool) {
60 c.mu.Lock()

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected