diff options
Diffstat (limited to 'pkg/priority_queue/interface.go')
-rw-r--r-- | pkg/priority_queue/interface.go | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/pkg/priority_queue/interface.go b/pkg/priority_queue/interface.go index 00998d78..45430486 100644 --- a/pkg/priority_queue/interface.go +++ b/pkg/priority_queue/interface.go @@ -1,6 +1,11 @@ package priorityqueue type Queue interface { - Push(item interface{}) - Pop() interface{} + Push(item PQItem) + Pop() PQItem +} + +type PQItem interface { + ID() string + Priority() uint64 } |