Versions in this module Expand all Collapse all v1 v1.1.0 Jan 9, 2024 Changes in this version + func Free(v *Value) type Value + func Alloc(n int) *Value v1.0.0 Oct 6, 2023 Changes in this version + type Cache struct + func New(size int64) *Cache + func (c *Cache) Alloc(n int) *Value + func (c *Cache) Delete(id uint64, fileNum base.FileNum, offset uint64) + func (c *Cache) EvictFile(id uint64, fileNum base.FileNum) + func (c *Cache) Free(v *Value) + func (c *Cache) Get(id uint64, fileNum base.FileNum, offset uint64) Handle + func (c *Cache) MaxSize() int64 + func (c *Cache) Metrics() Metrics + func (c *Cache) NewID() uint64 + func (c *Cache) Ref() + func (c *Cache) Reserve(n int) func() + func (c *Cache) Set(id uint64, fileNum base.FileNum, offset uint64, value *Value) Handle + func (c *Cache) Size() int64 + func (c *Cache) Unref() + type Handle struct + func (h Handle) Get() []byte + func (h Handle) Release() + type Metrics struct + Count int64 + Hits int64 + Misses int64 + Size int64 + type Value struct + func (v *Value) Buf() []byte + func (v *Value) Truncate(n int)