fifo

package
v1.0.1-0...-4a73120 Latest Latest
Warning

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

Go to latest
Published: Jun 11, 2017 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package fifo providers an in-memory cache container using FIFO (first in first out) arithmetic.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewContainer

func NewContainer(capacity int) caching.Container

NewContainer returns a new in-memory cache container using FIFO (first in first out) arithmetic.

Types

type Container

type Container struct {
	Capacity int
	// contains filtered or unexported fields
}

Container represents a FIFO caching container.

func (*Container) Clear

func (c *Container) Clear() error

func (*Container) Get

func (c *Container) Get(key string) (*caching.Item, error)

func (*Container) Put

func (c *Container) Put(item *caching.Item) error

func (*Container) Remove

func (c *Container) Remove(key string) error

Jump to

Keyboard shortcuts

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