queue

package
v0.1.13 Latest Latest
Warning

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

Go to latest
Published: Jun 27, 2017 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Drop added in v0.0.16

func Drop(queue string) error

Drop drops queue and all it's items

func Get added in v0.0.16

func Get(queue, _id string) (interface{}, error)

Get returns item from queue without removing from queue

func Init

func Init(file string)

Init is a main entry point for package

func Len added in v0.0.19

func Len(queue string) uint64

Len returns queue length

func Push

func Push(queue string, data interface{}) (err error)

Push adds item to the end of the queue

func Remove

func Remove(queue string, _id string) error

Remove removes item from queue by provided string _id property

func Shift added in v0.0.17

func Shift(queue string) (interface{}, error)

Shift returns first item from queue with FIFO algorythm

func Unshift

func Unshift(queue string, data interface{}) error

Unshift inserts item to the begining of the queue

Types

This section is empty.

Jump to

Keyboard shortcuts

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