Class NavigationComponentView
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
org.graffiti.plugin.gui.AbstractGraffitiComponent
org.graffiti.plugin.gui.AbstractGraffitiContainer
de.ipk_gatersleben.ag_nw.graffiti.plugins.gui.navigation.NavigationComponentView
- All Implemented Interfaces:
AdjustmentListener,ImageObserver,MenuContainer,Serializable,EventListener,Accessible,GraphListener,TransactionListener,GraffitiComponent,GraffitiContainer,SessionListener
public class NavigationComponentView extends AbstractGraffitiContainer implements AdjustmentListener, GraphListener, SessionListener
provides an overview view with navigation window, which allows to browse the
network. It is a view, which mimics the same features as e.g. photoshop
overview window, where the user has a complete picture including navigation
This view provides click, move and zoom operations
It preserves the scale of the network, even if the view has other dimensions
as the network
This view can be used anywhere, in a panel or a seperate frame
It listens to dedicated events in the current set view, to get information
about the position in the network
The component is initialised by using the setView Method
- Author:
- klapper
- See Also:
- Serialized Form
-
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponentNested classes/interfaces inherited from class java.awt.Component
Component.BaselineResizeBehavior -
Field Summary
Fields inherited from class javax.swing.JComponent
TOOL_TIP_TEXT_KEY, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOWFields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENTFields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH -
Constructor Summary
Constructors Constructor Description NavigationComponentView() -
Method Summary
Modifier and Type Method Description voidadjustmentValueChanged(AdjustmentEvent e)listener that listens to value changes of the scrollbar and simply repaintvoidpostEdgeAdded(GraphEvent e)Called after an edge has been added to the graph.voidpostEdgeRemoved(GraphEvent e)Called after an edge has been removed from the graph.voidpostGraphCleared(GraphEvent e)Called after methodclear()has been called on a graph.voidpostNodeAdded(GraphEvent e)Called after an edge has been added to the graph.voidpostNodeRemoved(GraphEvent e)Called after a node has been removed from the graph.voidpreEdgeAdded(GraphEvent e)Called just before an edge is added to the graph.voidpreEdgeRemoved(GraphEvent e)Called just before an edge is removed from the graph.voidpreGraphCleared(GraphEvent e)Called before methodclear()is called on a graph.voidpreNodeAdded(GraphEvent e)Called just before a node is added to the graph.voidpreNodeRemoved(GraphEvent e)Called just before a node is removed from the graph.voidsessionChanged(Session s)This method is called when the session changes.voidsessionDataChanged(Session s)This method is called when the data (except the graph data) are changed.voidsetView(View newview)voidtransactionFinished(TransactionEvent e, BackgroundTaskStatusProviderSupportingExternalCall status)Called when a transaction has stopped.voidtransactionStarted(TransactionEvent e)Called when a transaction has started.Methods inherited from class org.graffiti.plugin.gui.AbstractGraffitiContainer
getIdMethods inherited from class org.graffiti.plugin.gui.AbstractGraffitiComponent
getPreferredComponent, setMainFrameMethods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, setUI, updateUIMethods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, 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, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, 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, updateMethods inherited from class java.awt.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, transferFocusDownCycle, validateMethods inherited from class java.awt.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, getName, getParent, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, 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, requestFocus, requestFocusInWindow, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setMixingCutoutShape, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycleMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.graffiti.plugin.gui.GraffitiComponent
getPreferredComponent
-
Constructor Details
-
NavigationComponentView
public NavigationComponentView()
-
-
Method Details
-
sessionChanged
Description copied from interface:SessionListenerThis method is called when the session changes.- Specified by:
sessionChangedin interfaceSessionListener- Parameters:
s- the new Session.
-
sessionDataChanged
Description copied from interface:SessionListenerThis method is called when the data (except the graph data) are changed.- Specified by:
sessionDataChangedin interfaceSessionListener
-
setView
-
adjustmentValueChanged
listener that listens to value changes of the scrollbar and simply repaint- Specified by:
adjustmentValueChangedin interfaceAdjustmentListener
-
transactionFinished
public void transactionFinished(TransactionEvent e, BackgroundTaskStatusProviderSupportingExternalCall status)Description copied from interface:TransactionListenerCalled when a transaction has stopped.
The classTransactionHashMapmerges duplicateAttributeEvents. In case the Attribute path for the sameAttributableis not equal, detailed information about Attribute path is lost. Instead a genericAttributeEventcontaining just theAttributableis in the list of changed Objects (seeTransactionEvent).
In case no detailed information about an Attribute change is available, your code should completely re-process the affectedAttributable.- Specified by:
transactionFinishedin interfaceTransactionListener- Parameters:
e- the EdgeEvent detailing the changes.
-
transactionStarted
Description copied from interface:TransactionListenerCalled when a transaction has started.- Specified by:
transactionStartedin interfaceTransactionListener- Parameters:
e- the EdgeEvent detailing the changes.
-
postEdgeAdded
Description copied from interface:GraphListenerCalled after an edge has been added to the graph.- Specified by:
postEdgeAddedin interfaceGraphListener- Parameters:
e- the GraphEvent detailing the changes.
-
postEdgeRemoved
Description copied from interface:GraphListenerCalled after an edge has been removed from the graph.- Specified by:
postEdgeRemovedin interfaceGraphListener- Parameters:
e- the GraphEvent detailing the changes.
-
postGraphCleared
Description copied from interface:GraphListenerCalled after methodclear()has been called on a graph. No other events (like remove events) are generated.- Specified by:
postGraphClearedin interfaceGraphListener- Parameters:
e- the GraphEvent detailing the changes.
-
postNodeAdded
Description copied from interface:GraphListenerCalled after an edge has been added to the graph.- Specified by:
postNodeAddedin interfaceGraphListener- Parameters:
e- the GraphEvent detailing the changes.
-
postNodeRemoved
Description copied from interface:GraphListenerCalled after a node has been removed from the graph. All edges incident to this node have already been removed (preEdgeRemoved and postEdgeRemoved have been called).- Specified by:
postNodeRemovedin interfaceGraphListener- Parameters:
e- the GraphEvent detailing the changes.
-
preEdgeAdded
Description copied from interface:GraphListenerCalled just before an edge is added to the graph.- Specified by:
preEdgeAddedin interfaceGraphListener- Parameters:
e- the GraphEvent detailing the changes.
-
preEdgeRemoved
Description copied from interface:GraphListenerCalled just before an edge is removed from the graph.- Specified by:
preEdgeRemovedin interfaceGraphListener- Parameters:
e- the GraphEvent detailing the changes.
-
preGraphCleared
Description copied from interface:GraphListenerCalled before methodclear()is called on a graph. No other events (like remove events) are generated.- Specified by:
preGraphClearedin interfaceGraphListener- Parameters:
e- the GraphEvent detailing the changes.
-
preNodeAdded
Description copied from interface:GraphListenerCalled just before a node is added to the graph.- Specified by:
preNodeAddedin interfaceGraphListener- Parameters:
e- the GraphEvent detailing the changes.
-
preNodeRemoved
Description copied from interface:GraphListenerCalled just before a node is removed from the graph. This method is called before the incident edges are deleted.- Specified by:
preNodeRemovedin interfaceGraphListener- Parameters:
e- the GraphEvent detailing the changes.
-