inmemory

package
v0.0.0-...-3887b96 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2016 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNotExists = errors.New("task does not exist")
)

Functions

This section is empty.

Types

type Registry

type Registry struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

func New

func New() *Registry

func (*Registry) Delete

func (r *Registry) Delete(id string) error

func (*Registry) Fetch

func (r *Registry) Fetch(id string) (*types.Task, error)

func (*Registry) Register

func (r *Registry) Register(id string, task *types.Task) error

func (*Registry) Tasks

func (r *Registry) Tasks() ([]*types.Task, error)

func (*Registry) Update

func (r *Registry) Update(id string, t *types.Task) error

Jump to

Keyboard shortcuts

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