buffercache

package module
v0.0.0-...-98f301e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 17, 2015 License: Apache-2.0 Imports: 3 Imported by: 1

README

Build Status

buffercache

Buffer cache implementations in Go

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrKeyNotFound = errors.New("Key not found")
)

Functions

This section is empty.

Types

type BufferCache

type BufferCache interface {
	Get(key uint64, buf []byte) (err error)
	Set(key uint64, buf []byte) (err error)
	Invalidate(key uint64) (err error)
}

type ClockCache

type ClockCache struct {
	// contains filtered or unexported fields
}

func NewClockCache

func NewClockCache(cachesize, blocksize uint64) *ClockCache

func (*ClockCache) Get

func (c *ClockCache) Get(key uint64, buf []byte) (err error)

func (*ClockCache) Invalidate

func (c *ClockCache) Invalidate(key uint64) (err error)

func (*ClockCache) Set

func (c *ClockCache) Set(key uint64, buf []byte) (err error)

type ClockCacheBlock

type ClockCacheBlock struct {
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL