R - The row key type.C - The column key type.T - The value type.public interface KeyedValues2D<R extends java.lang.Comparable<R>,C extends java.lang.Comparable<C>,T> extends Values2D<T>
rowKey and the
columnKey). Any instance of Comparable can be
used as a key (String objects are instances of
Comparable, making them convenient key objects).| Modifier and Type | Method and Description |
|---|---|
int |
getColumnIndex(C columnKey)
Returns the index of the specified key, or
-1 if there
is no such key. |
C |
getColumnKey(int columnIndex)
Returns the column key with the specified index.
|
java.util.List<C> |
getColumnKeys()
Returns a list of the column keys (the order is significant, since data
values can be accessed by index as well as by key).
|
int |
getRowIndex(R rowKey)
Returns the index of the specified key, or
-1 if there
is no such key. |
R |
getRowKey(int rowIndex)
Returns the row key with the specified index.
|
java.util.List<R> |
getRowKeys()
Returns a list of the row keys (the order is significant, since data
values can be accessed by index as well as by key).
|
T |
getValue(R rowKey,
C columnKey)
Returns the value (possibly
null) associated with the
specified keys. |
getColumnCount, getDoubleValue, getRowCount, getValueR getRowKey(int rowIndex)
rowIndex - the row index.C getColumnKey(int columnIndex)
columnIndex - the index.int getRowIndex(R rowKey)
-1 if there
is no such key.rowKey - the row key (null not permitted).-1.int getColumnIndex(C columnKey)
-1 if there
is no such key.columnKey - the column key (null not permitted).-1.java.util.List<R> getRowKeys()
java.util.List<C> getColumnKeys()
T getValue(R rowKey, C columnKey)
null) associated with the
specified keys. If either or both of the keys is not defined in this
data structure, a runtime exception will be thrown.rowKey - the row key (null not permitted).columnKey - the column key (null not permitted).null).