org.jfree.data
public interface KeyedValues extends Values
null.
See Also: Values DefaultKeyedValues
| Method Summary | |
|---|---|
| int | getIndex(Comparable key)
Returns the index for a given key.
|
| Comparable | getKey(int index)
Returns the key associated with the item at a given position. |
| List | getKeys()
Returns the keys for the values in the collection. |
| Number | getValue(Comparable key)
Returns the value for a given key.
|
Parameters: key the key (null not permitted).
Returns: The index, or -1 if the key is unrecognised.
Throws: IllegalArgumentException if key is
null.
Parameters: index the item index (in the range 0 to
getItemCount() - 1).
Returns: The key (never null).
Throws: IndexOutOfBoundsException if index is not in the
specified range.
Returns: The keys (never null).
Parameters: key the key.
Returns: The value (possibly null).
Throws: UnknownKeyException if the key is not recognised.