queue: fixing doc after cherry pick
This commit just fixes a godoc and adds a new one to the already merged queue.PriorityQueue.
This commit is contained in:
parent
88e01fa1fa
commit
ff3063daea
@ -9,6 +9,8 @@ import (
|
|||||||
// PriorityQueue will be able to use that to build and restore an underlying
|
// PriorityQueue will be able to use that to build and restore an underlying
|
||||||
// heap.
|
// heap.
|
||||||
type PriorityQueueItem interface {
|
type PriorityQueueItem interface {
|
||||||
|
// Less must return true if this item is ordered before other and false
|
||||||
|
// otherwise.
|
||||||
Less(other PriorityQueueItem) bool
|
Less(other PriorityQueueItem) bool
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -43,7 +45,7 @@ func (pq *priorityQueue) Pop() interface{} {
|
|||||||
return item
|
return item
|
||||||
}
|
}
|
||||||
|
|
||||||
// Priority wrap a standard heap in a more object-oriented structure.
|
// PriorityQueue wraps a standard heap into a self contained class.
|
||||||
type PriorityQueue struct {
|
type PriorityQueue struct {
|
||||||
queue priorityQueue
|
queue priorityQueue
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user