Documentation
¶
Overview ¶
Package bufferqueue implements a buffer queue.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BufferQueue ¶
type BufferQueue interface {
PushItem(i *Item)
Push(any interface{})
Pop() interface{}
Len() int
Workings() int32
SetLimit(n int64)
GraceFullStop(ctx context.Context)
}
func New ¶
func New(opt *Options) BufferQueue
type TimeSortedQueue ¶
type TimeSortedQueue []*Item
func (TimeSortedQueue) Len ¶
func (pq TimeSortedQueue) Len() int
func (TimeSortedQueue) Less ¶
func (pq TimeSortedQueue) Less(i, j int) bool
func (*TimeSortedQueue) Pop ¶
func (pq *TimeSortedQueue) Pop() interface{}
func (*TimeSortedQueue) Push ¶
func (pq *TimeSortedQueue) Push(x interface{})
func (TimeSortedQueue) Swap ¶
func (pq TimeSortedQueue) Swap(i, j int)
type WorkHandler ¶
type WorkHandler interface {
Handle()
}
Click to show internal directories.
Click to hide internal directories.