|
|
@ -1010,8 +1010,8 @@ func New(defaultExpiration, cleanupInterval time.Duration) *Cache {
|
|
|
|
//
|
|
|
|
//
|
|
|
|
// Only the cache's methods synchronize access to this map, so it is not
|
|
|
|
// Only the cache's methods synchronize access to this map, so it is not
|
|
|
|
// recommended to keep any references to the map around after creating a cache.
|
|
|
|
// recommended to keep any references to the map around after creating a cache.
|
|
|
|
// If need be, the map can be accessed at a later point using c.Items() (with
|
|
|
|
// If need be, the map can be accessed at a later point using c.Items() (subject
|
|
|
|
// the same caveats.)
|
|
|
|
// to the same caveat.)
|
|
|
|
//
|
|
|
|
//
|
|
|
|
// Note regarding serialization: When using e.g. gob, make sure to gob.Register
|
|
|
|
// Note regarding serialization: When using e.g. gob, make sure to gob.Register
|
|
|
|
// the individual types stored in the cache before encoding a map retrieved with
|
|
|
|
// the individual types stored in the cache before encoding a map retrieved with
|
|
|
|