pathcache

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jan 30, 2019 License: BSD-2-Clause Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PathCache

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

PathCache provides general interface to cache find and search queries

func NewPathCache

func NewPathCache(ExpireDelaySec int32) PathCache

NewPathCache initializes PathCache structure

func (*PathCache) ECItems

func (p *PathCache) ECItems() int

ECItems returns amount of items in the cache

func (*PathCache) ECSize

func (p *PathCache) ECSize() uint64

ECSize returns size of the cache

func (*PathCache) Get

func (p *PathCache) Get(k string) ([]string, bool)

Get returns an an element by key. If not successful - returns also false in second var.

func (*PathCache) Set

func (p *PathCache) Set(k string, v []string)

Set allows to set a key (k) to value (v).

Jump to

Keyboard shortcuts

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