MCPcopy Create free account
hub / github.com/patrickmn/go-cache / newCache

Function newCache

cache.go:1102–1111  ·  view source on GitHub ↗
(de time.Duration, m map[string]Item)

Source from the content-addressed store, hash-verified

1100}
1101
1102func newCache(de time.Duration, m map[string]Item) *cache {
1103 if de == 0 {
1104 de = -1
1105 }
1106 c := &cache{
1107 defaultExpiration: de,
1108 items: m,
1109 }
1110 return c
1111}
1112
1113func newCacheWithJanitor(de time.Duration, ci time.Duration, m map[string]Item) *Cache {
1114 c := newCache(de, m)

Callers 1

newCacheWithJanitorFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…