|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectinfovis.utils.ChangeManager
infovis.column.AbstractColumn
infovis.column.BasicColumn
infovis.column.SparseColumn
public abstract class SparseColumn
Base class for sparse columns, i˙e˙ columns containing few elements.
A sparse column is implemented with an IntSortedMap
.
Field Summary |
---|
Fields inherited from class infovis.column.AbstractColumn |
---|
MODIFIED_ALL, MODIFIED_NONE |
Fields inherited from interface infovis.metadata.Constants |
---|
CONTRIBUTOR, COVERAGE, CREATOR, DATE, DESCRITION, FORMAT, IDENTIFIER, LANGUAGE, PUBLISHER, RELATION, RIGHTS, SOURCE, SUBJECT, TITLE, TYPE |
Constructor Summary | |
---|---|
SparseColumn(String name)
Constructor for SparseColumn. |
Method Summary | |
---|---|
int |
capacity()
Returns the current capacity of this column. |
void |
clear()
Removes all of the elements from this column. The Column will be empty after this call returns. WARNING: if there is an associated format that maintains a status, such as a CategoricalFormat , it
is not cleared so results may not be what you expected. The
CategoricalFormat can be cleared explicitely if
needed. |
void |
ensureCapacity(int minCapacity)
Increases the capacity of this column, if necessary, to ensure that it can hold at least the number of values specified by the minimum capacity argument. |
boolean |
isValueUndefined(int i)
Returns true if the ith value is undefined. |
void |
setSize(int newSize)
Sets the sizeColumn of this column. |
void |
setValueUndefined(int i,
boolean undef)
Sets the ith element to have an undefined value. |
int |
size()
Returns the number of elements in this column. |
Methods inherited from class infovis.column.BasicColumn |
---|
addValue, addValueOrNull, compare, firstValidRow, getClientProperty, getFormat, getMaxIndex, getMetadata, getMinIndex, getName, getValueClass, isEmpty, isInternal, iterator, lastValidRow, setFormat, setName, setValueOrNullAt, toString |
Methods inherited from class infovis.column.AbstractColumn |
---|
addChangeListener, compareValues, computeValueMap, computeValueMap, equalObj, equals, getLastModifiedRow |
Methods inherited from class infovis.utils.ChangeManager |
---|
disableNotify, enableNotify, getModCount, removeChangeListener |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.Comparator |
---|
compare, equals |
Methods inherited from interface infovis.Column |
---|
disableNotify, enableNotify, getValueAt, hasUndefinedValue, removeChangeListener, setValueAt |
Constructor Detail |
---|
public SparseColumn(String name)
name
- the colum name.Method Detail |
---|
public int capacity()
capacity
in interface Column
public void clear()
CategoricalFormat
, it
is not cleared so results may not be what you expected. The
CategoricalFormat
can be cleared explicitely if
needed.
clear
in interface Column
clear
in class BasicColumn
public void ensureCapacity(int minCapacity)
ensureCapacity
in interface Column
minCapacity
- the desired minimum capacity.public int size()
size
in interface Column
public boolean isValueUndefined(int i)
isValueUndefined
in interface Column
isValueUndefined
in interface RowComparator
i
- the index
public void setSize(int newSize)
0
items
are added to the end of the column. If the new sizeColumn is
less than the current sizeColumn, all components at index
newSize
and greater are discarded.
setSize
in interface Column
setSize
in class BasicColumn
newSize
- the new sizeColumn of this column.public void setValueUndefined(int i, boolean undef)
setValueUndefined
in interface Column
i
- the indexundef
- true if the value should be undefined,
false otherwise.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |