package
Version:
v0.0.0-...-f8b7a73
Opens a new window with list of versions in this module.
Published: Mar 16, 2019
License: GPL-3.0
Opens a new window with license information.
Imports: 1
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
优先级队列数据结构。
func New(setIndex setIndexCallback) *Prque
创建新的优先级队列。
从堆栈中弹出优先级为greates的值并返回该值。
目前还没有收缩。
func (p *Prque) PopItem() interface{}
只从队列中弹出项目,删除关联的优先级值。
func (p *Prque) Push(data interface{}, priority int64)
将具有给定优先级的值推入队列,必要时展开。
func (p *Prque) Remove(i int) interface{}
移除移除具有给定索引的元素。
Source Files
¶
Click to show internal directories.
Click to hide internal directories.