|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
ObjectComponent
Container
JComponent
JGraph
ImprovedJGraph<NodeType,NodeData,EdgeType,EdgeData>
JDomGraph
public class JDomGraph
A Swing component that represents a labelled dominance graph.
ImprovedJGraph
,
Serialized FormNested Class Summary |
---|
Nested classes/interfaces inherited from class ImprovedJGraph |
---|
ImprovedJGraph.EdgeSortingComparator |
Nested classes/interfaces inherited from class JGraph |
---|
JGraph.EmptySelectionModel |
Nested classes/interfaces inherited from class JComponent |
---|
JComponent.AccessibleJComponent |
Field Summary |
---|
Fields inherited from class JGraph |
---|
ANTIALIASED_PROPERTY, CROSS_GRID_MODE, DOT_GRID_MODE, EDITABLE_PROPERTY, GRAPH_LAYOUT_CACHE_PROPERTY, GRAPH_MODEL_PROPERTY, GRID_SIZE_PROPERTY, GRID_VISIBLE_PROPERTY, INVOKES_STOP_CELL_EDITING_PROPERTY, LINE_GRID_MODE, MARQUEE_HANDLER_PROPERTY, PORTS_VISIBLE_PROPERTY, SCALE_PROPERTY, SELECTION_MODEL_PROPERTY, VERSION |
Fields inherited from class JComponent |
---|
TOOL_TIP_TEXT_KEY, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
JDomGraph(DomGraph origin)
Sets up an empty dominance graph. |
Method Summary | |
---|---|
void |
addPopupListener(DomGraphPopupListener listener)
Add a popup listener. |
void |
addSampleData()
Add some sample nodes and edges to the graph. |
void |
addSampleFragmentMenus()
Once the fragments have been computed, add some sample menu items to them. |
void |
clear()
Remove all nodes and edges in the graph. |
void |
clearDominanceEdges()
Removes all dominance edges from this graph. |
JDomGraph |
clone()
Clones this graph. |
void |
computeFragments()
Group the nodes of the graph into the maximal fragments. |
void |
computeLayout()
Apply a layout algorithm to this graph. |
Fragment |
findFragment(DefaultGraphCell cell)
Return the fragment a node or edge belongs to. |
Rectangle |
getBoundingBox()
|
Set<DefaultEdge> |
getDominanceEdges()
|
Set<Fragment> |
getFragments()
Get the set of all fragments. |
Fragment |
getSourceFragment(DefaultEdge edge)
Returns the fragment the source node of an edge belongs to. |
Fragment |
getTargetFragment(DefaultEdge edge)
Returns the fragment the target node of an edge belongs to. |
Set<Fragment> |
getWccFragments(Set<DefaultGraphCell> wcc)
Computes the Fragments contained in a wcc. |
List<Set<DefaultGraphCell>> |
getWccs()
|
boolean |
isFragLeaf(DefaultGraphCell node)
Determines whether a given node is a leaf in its fragment. |
boolean |
isFragRoot(DefaultGraphCell node)
Determines wheter a given node is the root of its fragment. |
boolean |
isHnc()
|
void |
printPositions()
prints position and dimensions of all fragments and their node on screen. |
void |
removePopupListener(DomGraphPopupListener listener)
Remove a popup listener. |
void |
setBoundingBox(Rectangle boundingBox)
|
void |
setShowLabels(boolean b)
Changing the preferences for displaying node labels |
Methods inherited from class JGraph |
---|
addGraphSelectionListener, addSampleData, addSelectionCell, addSelectionCells, cancelEditing, clearSelection, cloneCells, convertValueToString, createBounds, createView, fromScreen, fromScreen, getCellBounds, getCellBounds, getDescendantList, getDescendants, getEditClickCount, getEditingCell, getFirstCellForLocation, getGraphLayoutCache, getGridColor, getGridMode, getGridSize, getHandleColor, getHandleSize, getHighlightColor, getInvokesStopCellEditing, getLockedHandleColor, getMarqueeColor, getMarqueeHandler, getMinimumMove, getModel, getNextCellForLocation, getNextViewAt, getNextViewAt, getPortForLocation, getPortViewAt, getPreferredScrollableViewportSize, getRoots, getRoots, getScale, getScrollableBlockIncrement, getScrollableTracksViewportHeight, getScrollableTracksViewportWidth, getScrollableUnitIncrement, getSelectionCell, getSelectionCells, getSelectionCount, getSelectionModel, getTolerance, getUI, getUIClassID, graphDidChange, isAntiAliased, isBendable, isCellEditable, isCellSelected, isCloneable, isConnectable, isDisconnectable, isDisconnectOnMove, isDragEnabled, isDropEnabled, isEditable, isEditing, isGridEnabled, isGridVisible, isMoveable, isMoveBelowZero, isPortsVisible, isSelectionEmpty, isSelectNewCells, isSizeable, main, removeGraphSelectionListener, removeSelectionCell, scrollCellToVisible, scrollPointToVisible, setAntiAliased, setBendable, setCloneable, setConnectable, setDisconnectable, setDisconnectOnMove, setDragEnabled, setDropEnabled, setEditable, setEditClickCount, setGraphLayoutCache, setGridColor, setGridEnabled, setGridMode, setGridSize, setGridVisible, setHandleColor, setHandleSize, setHighlightColor, setInvokesStopCellEditing, setLockedHandleColor, setMarqueeColor, setMarqueeHandler, setMinimumMove, setModel, setMoveable, setMoveBelowZero, setPortsVisible, setScale, setSelectionCell, setSelectionCells, setSelectionModel, setSelectNewCells, setSizeable, setTolerance, setUI, snap, snap, startEditingAtCell, stopEditing, toScreen, toScreen, updateAutoSize, updateUI |
Methods inherited from class JComponent |
---|
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, getAccessibleContext, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintImmediately, paintImmediately, print, printAll, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update |
Methods inherited from class Container |
---|
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate |
Methods inherited from class Component |
---|
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, contains, createImage, createImage, createVolatileImage, createVolatileImage, dispatchEvent, enable, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle |
Methods inherited from class Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface Accessible |
---|
getAccessibleContext |
Constructor Detail |
---|
public JDomGraph(DomGraph origin)
origin
- the DomGraph
represented here.Method Detail |
---|
public void clear()
clear
in class ImprovedJGraph<NodeType,NodeData,EdgeType,EdgeData>
public void addSampleData()
public void addSampleFragmentMenus()
public void printPositions()
public void computeLayout()
computeLayout
in class ImprovedJGraph<NodeType,NodeData,EdgeType,EdgeData>
public void computeFragments()
public Set<DefaultEdge> getDominanceEdges()
public Set<Fragment> getFragments()
public void addPopupListener(DomGraphPopupListener listener)
listener
- public void removePopupListener(DomGraphPopupListener listener)
listener
- public Fragment findFragment(DefaultGraphCell cell)
cell
- a node or edge in the graph
public Fragment getSourceFragment(DefaultEdge edge)
edge
- the edge
public Fragment getTargetFragment(DefaultEdge edge)
edge
- the edge
public Rectangle getBoundingBox()
public void setBoundingBox(Rectangle boundingBox)
boundingBox
- The boundingBox to set.public JDomGraph clone()
clone
in class Object
public boolean isFragLeaf(DefaultGraphCell node)
node
- the node
public boolean isFragRoot(DefaultGraphCell node)
node
- the node
public void setShowLabels(boolean b)
b
- indicating whether or not to show labels (insted
of names, default is true)public void clearDominanceEdges()
public Set<Fragment> getWccFragments(Set<DefaultGraphCell> wcc)
wcc
- a Set
of nodes
Set
of fragments represented by the argument node setpublic boolean isHnc()
public List<Set<DefaultGraphCell>> getWccs()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |