cache

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2021 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const DEBUG = true

Variables

This section is empty.

Functions

This section is empty.

Types

type Cacher

type Cacher struct {
	Data resultCache
	// contains filtered or unexported fields
}
var Global *Cacher = New()

func New

func New() *Cacher

func (*Cacher) Cache

func (c *Cacher) Cache(cn string, k uint64, v []*query2.Record) []*query2.Record

func (*Cacher) Reset

func (c *Cacher) Reset()

type CountCache

type CountCache struct {
	// contains filtered or unexported fields
}
var Counter *CountCache = CountNew()

func CountNew

func CountNew() *CountCache

func (*CountCache) Cache

func (c *CountCache) Cache(cn string, k uint64, v int) int

func (*CountCache) Raw

func (c *CountCache) Raw() map[string]map[uint64]int

func (*CountCache) Reset

func (c *CountCache) Reset()

Jump to

Keyboard shortcuts

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