queue

package
v0.0.0-...-b9dd322 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2019 License: GPL-3.0 Imports: 0 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Item

type Item interface {
}

type ItemQueue

type ItemQueue interface {
	Init() Queue
	Enqueue(t Item)
	Dequeue() *Item
	IsEmpty() bool
	Size() int
}

type Queue

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

Item the type of the queue

func NewQueue

func NewQueue() *Queue

func (*Queue) Dequeue

func (s *Queue) Dequeue() Item

dequeue

func (*Queue) Enqueue

func (s *Queue) Enqueue(t Item)

Enqueue adds an Item to the end of the queue

func (*Queue) Init

func (s *Queue) Init() *Queue

New creates a new ItemQueue

func (*Queue) IsEmpty

func (s *Queue) IsEmpty() bool

func (*Queue) Size

func (s *Queue) Size() int

Size returns the number of Items in the queue

Jump to

Keyboard shortcuts

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