K - the key type (must implement Comparable).T - the value type.public interface KeyedValues<K extends java.lang.Comparable<K>,T> extends Values<T>
| Modifier and Type | Method and Description |
|---|---|
int |
getIndex(K key)
Returns the index for the specified key, or
-1 if the key
is not present in the list. |
K |
getKey(int index)
Returns the key for the specified item in the list.
|
java.util.List<K> |
getKeys()
Returns a list of all the keys.
|
T |
getValue(K key)
Returns the value associated with the specified key, or
null. |
getDoubleValue, getItemCount, getValueK getKey(int index)
index - the item index.int getIndex(K key)
-1 if the key
is not present in the list.key - the key (null not permitted).-1.java.util.List<K> getKeys()
null).