queues

package module
v0.0.0-...-8b5a301 Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2017 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BoltDbQueue

type BoltDbQueue struct {
	Db           *bolt.DB
	ElementTypes []interface{}
	// contains filtered or unexported fields
}

func (*BoltDbQueue) Close

func (q *BoltDbQueue) Close() error

func (*BoltDbQueue) Dequeue

func (q *BoltDbQueue) Dequeue(peek ...bool) (interface{}, bool, error)

func (*BoltDbQueue) Enqueue

func (q *BoltDbQueue) Enqueue(v interface{}) error

func (*BoltDbQueue) Open

func (q *BoltDbQueue) Open() error

type ChanQueue

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

func (*ChanQueue) Close

func (q *ChanQueue) Close() error

func (*ChanQueue) Dequeue

func (q *ChanQueue) Dequeue(peek ...bool) (interface{}, bool, error)

func (*ChanQueue) Enqueue

func (q *ChanQueue) Enqueue(v interface{}) error

func (*ChanQueue) Open

func (q *ChanQueue) Open() error

type ComposeFunc

type ComposeFunc func(q Queue) (Queue, error)

func Compose

func Compose(fs ...ComposeFunc) ComposeFunc

func Filter

func Filter(f FilterFunc) ComposeFunc

func FilterTo

func FilterTo(outQ Queue, f FilterFunc) ComposeFunc

func ForkJoin

func ForkJoin(f ForkJoinFunc, cfs ...ComposeFunc) ComposeFunc

func ForkJoinTo

func ForkJoinTo(outQ Queue, f ForkJoinFunc, cfs ...ComposeFunc) ComposeFunc

func Map

func Map(f MapFunc) ComposeFunc

func MapTo

func MapTo(outQ Queue, f MapFunc) ComposeFunc

func Partition

func Partition(f PartitionFunc) ComposeFunc

func PartitionTo

func PartitionTo(outQ Queue, f PartitionFunc) ComposeFunc

func Reduce

func Reduce(f ReduceFunc) ComposeFunc

func ReduceTo

func ReduceTo(outQ Queue, f ReduceFunc) ComposeFunc

type FilterFunc

type FilterFunc func(v interface{}) (bool, error)

type ForkJoinFunc

type ForkJoinFunc func(v interface{}) (map[int]interface{}, error)

type ListQueue

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

func (*ListQueue) Close

func (q *ListQueue) Close() error

func (*ListQueue) Dequeue

func (q *ListQueue) Dequeue(peek ...bool) (interface{}, bool, error)

func (*ListQueue) Enqueue

func (q *ListQueue) Enqueue(v interface{}) error

func (*ListQueue) Open

func (q *ListQueue) Open() error

type MapFunc

type MapFunc func(v interface{}) (interface{}, error)

type PartitionFunc

type PartitionFunc func(partition, v interface{}) (interface{}, error)

type Queue

type Queue interface {
	Open() error
	Close() error
	Enqueue(v interface{}) error
	Dequeue(peek ...bool) (interface{}, bool, error)
}

type ReduceFunc

type ReduceFunc func(acc, v interface{}) (interface{}, error)

Jump to

Keyboard shortcuts

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