pqueues

package
v0.0.0-...-b785d8d Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2015 License: BSD-3-Clause Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Queue

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

A path queue that uses a flow heap

func NewQueue

func NewQueue() *Queue

func (*Queue) Pull

func (self *Queue) Pull(n uint64, next blocks.Block, loc, drop int) uint64

Pull n number of bytes, move them to block, mark it as moving to location "loc" on the packet trace and set dropBy to drop if the location is a drop

func (*Queue) Push

func (self *Queue) Push(p *packet.Packet)

Push a packet into the queue

func (*Queue) Send

func (self *Queue) Send(p *packet.Packet) uint64

type Queues

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

A path queue that uses a flow heap

This is very similar to queues.Queues.  I probably should merge them
with some abstraction, but a queue supports pulling from back and also
dropping, so it generalizing that is a little bit complicated.

I might generalize that later. For now, I need something that just works.

func NewQueues

func NewQueues() *Queues

func (*Queues) Len

func (self *Queues) Len() structs.Matrix

func (*Queues) Move

func (self *Queues) Move(size structs.Matrix,
	next blocks.Block, loc int, ret structs.Matrix)

func (*Queues) MoveUsing

func (self *Queues) MoveUsing(next blocks.Block, loc int,
	puller queues.Puller) (buf structs.Matrix, pulled structs.Matrix)

func (*Queues) Push

func (self *Queues) Push(p *packet.Packet)

func (*Queues) Send

func (self *Queues) Send(p *packet.Packet) uint64

Jump to

Keyboard shortcuts

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