Implementato HashCode Dictionary via LinearProbing (Open Adress) e Chaining.

This commit is contained in:
2014-05-11 22:47:12 +02:00
parent 597626b34c
commit 53d6129052
19 changed files with 961 additions and 18 deletions

View File

@@ -0,0 +1,24 @@
package dictionary;
import exceptions.InvalidEntryException;
import priorityqueue.Entry;
import java.security.InvalidKeyException;
public interface Dictionary<K,V> {
public int size();
public boolean isEmpty();
public Entry<K,V> find(K key) throws InvalidKeyException;
public Iterable<Entry<K,V>> findAll(K key) throws InvalidKeyException;
public Entry<K,V> insert(K key, V value) throws InvalidKeyException;
public Entry<K,V> remove(Entry<K, V> e) throws InvalidEntryException;
public Iterable<Entry<K,V>> entries();
}