|
||||||||||
| 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.ColumnProxy
infovis.table.TableProxy
infovis.visualization.DefaultVisualization
infovis.tree.visualization.TreeVisualization
public class TreeVisualization
Abstract base class for tree visualizations.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface infovis.visualization.magicLens.LabeledComponent |
|---|
LabeledComponent.LabeledItem |
| Field Summary | |
|---|---|
static String |
PROPERTY_ROOT
Property name for the visible root field. |
static String |
SORTEDCHILDREN_COLUMN
Name of the column containing the sorted children of the tree. |
static String |
WEIGHT_COLUMN
Name of the column where the additive weights are computed. |
| Fields inherited from class infovis.column.AbstractColumn |
|---|
MODIFIED_ALL, MODIFIED_NONE |
| Fields inherited from interface infovis.Tree |
|---|
ROOT, TREE_METADATA |
| Fields inherited from interface infovis.Table |
|---|
FILTER_COLUMN, INTERNAL_PREFIX, NIL, SELECTION_COLUMN |
| Fields inherited from interface infovis.metadata.Constants |
|---|
CONTRIBUTOR, COVERAGE, CREATOR, DATE, DESCRITION, FORMAT, IDENTIFIER, LANGUAGE, PUBLISHER, RELATION, RIGHTS, SOURCE, SUBJECT, TITLE, TYPE |
| Fields inherited from interface infovis.Visualization |
|---|
PROPERTY_INTERACTOR, PROPERTY_ITEM_RENDERER, PROPERTY_LAYOUT, PROPERTY_ORIENTATION, PROPERTY_PARENT, PROPERTY_PERMUTATION, PROPERTY_RULERS, VC_DESCRIPTOR_PROPERTY_PREFIX, VISUAL_ALPHA, VISUAL_COLOR, VISUAL_FILTER, VISUAL_HOVER, VISUAL_LABEL, VISUAL_SELECTION, VISUAL_SHAPE, VISUAL_SIZE |
| Fields inherited from interface infovis.visualization.Orientable |
|---|
DIRECTION, NAME, ORIENTATION_CENTER, ORIENTATION_EAST, ORIENTATION_INVALID, ORIENTATION_NORTH, ORIENTATION_SOUTH, ORIENTATION_WEST, SQRT2 |
| Fields inherited from interface javax.swing.SwingConstants |
|---|
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST |
| Constructor Summary | |
|---|---|
TreeVisualization(Tree tree)
Constructor for TreeVisualization. |
|
TreeVisualization(Tree tree,
ItemRenderer ir)
Constructor for TreeVisualization. |
|
| Method Summary | |
|---|---|
int |
addNode(int par)
Adds a node to the tree. |
int |
addRow()
Creates a new row and returns it. |
void |
addTreeModelListener(TreeModelListener l)
|
boolean |
apply(int node)
|
RowIterator |
childrenIterator(int node)
Returns the iterator over the children of a node. |
int |
getChild(int node,
int index)
Returns the nth child of a node. |
Object |
getChild(Object parent,
int index)
|
int |
getChildCount(int node)
Returns the number of children of a node. |
int |
getChildCount(Object parent)
|
int |
getDepth(int node)
Returns the depth of a node using either a depth column if it has been computed or the computeDepth method. |
int |
getFirstChild(int node)
Returns the first child of a specified node or NIL. |
int |
getIndexOfChild(Object parent,
Object child)
|
int |
getNodeCount()
Returns the number of proper nodes in the Tree. |
int |
getParent(int node)
Returns the parent of a node. |
Object |
getRoot()
|
DoubleFunction |
getTransformFunction()
Returns the transform function applied to weights or null. |
Tree |
getTree()
Returns the tree. |
int |
getVisibleRoot()
Returns the visible root. |
NumberColumn |
getWeightColumn()
Returns an additive weighted column from the specified size column. |
boolean |
isAncestor(int node,
int par)
Returns true if the first node has the second node as ancestor. |
boolean |
isLeaf(int node)
Returns true if the node is a leaf_node. |
boolean |
isLeaf(Object node)
|
int |
nextNode()
Returns the next node to be returned by addNode. |
void |
paintItems(Graphics2D graphics,
Rectangle2D bounds)
Method for filtering and painting the items. |
boolean |
removeNode(int node)
Removes a node from the tree. |
void |
removeRow(int row)
Removes a specified row. |
void |
removeTreeModelListener(TreeModelListener l)
|
void |
reparent(int node,
int newparent)
Change the parent of a specified node, changing the structure. |
RowIterator |
reverseIterator()
Returns an iterator over the columns of this table in reverse order. |
void |
setPermutation(Permutation permutation)
Sets the permutation. |
void |
setTransformFunction(DoubleFunction transformFunction)
Sets the transform function applied to weights or null. |
void |
setVisibleRoot(int root)
Sets the visible root. |
void |
valueForPathChanged(TreePath path,
Object newValue)
|
| Methods inherited from class infovis.table.TableProxy |
|---|
addColumn, addTableModelListener, clear, getColumn, getColumnAt, getColumnClass, getColumnCount, getColumnName, getLastRow, getValueAt, indexOf, indexOf, isCellEditable, isRowValid, removeColumn, removeTableModelListener, setColumnAt, setValueAt |
| Methods inherited from class infovis.column.ColumnProxy |
|---|
addValue, addValueOrNull, capacity, compare, ensureCapacity, getClientProperty, getFormat, getMaxIndex, getMetadata, getMinIndex, getName, getValueAt, getValueClass, hasUndefinedValue, isEmpty, isInternal, isValueUndefined, setFormat, setName, setSize, setValueAt, setValueOrNullAt, setValueUndefined, size |
| Methods inherited from class infovis.column.AbstractColumn |
|---|
addChangeListener, compareValues, computeValueMap, computeValueMap, equalObj, equals, getLastModifiedRow, toString |
| Methods inherited from class infovis.utils.ChangeManager |
|---|
disableNotify, enableNotify, getModCount, removeChangeListener |
| Methods inherited from class java.lang.Object |
|---|
getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface infovis.Table |
|---|
addColumn, clear, getColumn, getColumnAt, getColumnCount, getLastRow, getRowCount, getTable, indexOf, indexOf, isRowValid, removeColumn, setColumnAt |
| Methods inherited from interface infovis.Column |
|---|
addChangeListener, addValue, addValueOrNull, capacity, disableNotify, enableNotify, ensureCapacity, getFormat, getMaxIndex, getMinIndex, getName, getValueAt, getValueClass, hasUndefinedValue, isEmpty, isInternal, isValueUndefined, iterator, removeChangeListener, setFormat, setName, setSize, setValueAt, setValueOrNullAt, setValueUndefined, size |
| Methods inherited from interface infovis.Metadata |
|---|
getClientProperty, getMetadata |
| Methods inherited from interface cern.colt.function.IntComparator |
|---|
compare, equals |
| Methods inherited from interface javax.swing.table.TableModel |
|---|
addTableModelListener, getColumnClass, getColumnName, getValueAt, isCellEditable, removeTableModelListener, setValueAt |
| Field Detail |
|---|
public static final String PROPERTY_ROOT
public static final String SORTEDCHILDREN_COLUMN
public static final String WEIGHT_COLUMN
| Constructor Detail |
|---|
public TreeVisualization(Tree tree)
tree - the Tree.
public TreeVisualization(Tree tree,
ItemRenderer ir)
tree - the treeir - the ItemRenderer root| Method Detail |
|---|
public Tree getTree()
public void paintItems(Graphics2D graphics,
Rectangle2D bounds)
paintItems in class DefaultVisualizationgraphics - the graphics.bounds - the bounding box of the visualization.public boolean apply(int node)
apply in interface IntProcedurepublic int getVisibleRoot()
public void setVisibleRoot(int root)
root - The visible root to setpublic NumberColumn getWeightColumn()
public DoubleFunction getTransformFunction()
public void setTransformFunction(DoubleFunction transformFunction)
transformFunction - the transform function.public void setPermutation(Permutation permutation)
setPermutation in interface VisualizationsetPermutation in class DefaultVisualizationpermutation - The permutation to setpublic RowIterator childrenIterator(int node)
childrenIterator in interface Treenode - the node
public int addNode(int par)
addNode in interface Treepar - the parent of the node.
public int addRow()
addRow in interface DynamicTablepublic void removeRow(int row)
removeRow in interface DynamicTablerow - the row to remove.public boolean removeNode(int node)
removeNode in interface Treenode - the node to remove
public int getChild(int node,
int index)
getChild in interface Treenode - the nodeindex - the index if the requested child
public int getChildCount(int node)
node.
getChildCount in interface Treenode - the node.
node.public int getDepth(int node)
getDepth in interface Treenode - the node.
public int getFirstChild(int node)
node - the node
public int getParent(int node)
getParent in interface Treenode - the node
public boolean isAncestor(int node,
int par)
isAncestor in interface Treenode - the node.par - the tested ancestor.
public boolean isLeaf(int node)
isLeaf in interface Treenode - the node
public void reparent(int node,
int newparent)
reparent in interface Treenode - the node.newparent - the new parent.public int nextNode()
nextNode in interface Treepublic RowIterator reverseIterator()
reverseIterator in interface TablereverseIterator in interface VisualizationreverseIterator in class DefaultVisualizationpublic int getNodeCount()
getNodeCount in interface Treepublic void addTreeModelListener(TreeModelListener l)
addTreeModelListener in interface TreeModel
public Object getChild(Object parent,
int index)
getChild in interface TreeModelpublic int getChildCount(Object parent)
getChildCount in interface TreeModel
public int getIndexOfChild(Object parent,
Object child)
getIndexOfChild in interface TreeModelpublic Object getRoot()
getRoot in interface TreeModelpublic boolean isLeaf(Object node)
isLeaf in interface TreeModelpublic void removeTreeModelListener(TreeModelListener l)
removeTreeModelListener in interface TreeModel
public void valueForPathChanged(TreePath path,
Object newValue)
valueForPathChanged in interface TreeModel
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||