net.datastructures
Interface AdaptablePriorityQueue<K,V>

All Superinterfaces:
PriorityQueue<K,V>
All Known Implementing Classes:
HeapAdaptablePriorityQueue, SortedListAdaptablePriorityQueue

public interface AdaptablePriorityQueue<K,V>
extends PriorityQueue<K,V>

Interface for an adaptable priority queue.


Method Summary
 Entry<K,V> remove(Entry<K,V> e)
          Removes and returns an entry from the priority queue.
 K replaceKey(Entry<K,V> e, K key)
          Replaces the key of an entry and returns the old key.
 V replaceValue(Entry<K,V> e, V value)
          Replaces the value of an entry and returns the old value.
 
Methods inherited from interface net.datastructures.PriorityQueue
insert, isEmpty, min, removeMin, size
 

Method Detail

remove

Entry<K,V> remove(Entry<K,V> e)
Removes and returns an entry from the priority queue.


replaceKey

K replaceKey(Entry<K,V> e,
             K key)
             throws InvalidKeyException
Replaces the key of an entry and returns the old key.

Throws:
InvalidKeyException

replaceValue

V replaceValue(Entry<K,V> e,
               V value)
Replaces the value of an entry and returns the old value.