org.globus.cog.gui.grapheditor.targets.swing
Class AbstractSwingRenderer

java.lang.Object
  extended by org.globus.cog.gui.grapheditor.AbstractRenderer
      extended by org.globus.cog.gui.grapheditor.targets.swing.AbstractSwingRenderer
All Implemented Interfaces:
ActionListener, MouseListener, PropertyChangeListener, EventListener, ComponentRenderer, GraphComponentListener, SwingComponentRenderer, EventConsumer
Direct Known Subclasses:
AntRenderer, IconRenderer, SwingEdgeRenderer, SwingNodeRenderer

public abstract class AbstractSwingRenderer
extends AbstractRenderer
implements MouseListener, SwingComponentRenderer, EventConsumer


Constructor Summary
AbstractSwingRenderer()
           
 
Method Summary
 void actionPerformed(ActionEvent e)
           
 void addAction(ComponentAction action)
          Adds an action to this component.
 void event(EventObject e)
           
 ComponentAction getAction(String name)
          Returns an action with the name specified by the name parameter
 List getActions()
          Returns a list of actions that were added to this component.
 JMenu getMenu()
           
 Component getVisualComponent()
           
 void mouseClicked(MouseEvent e)
           
 void mouseEntered(MouseEvent e)
           
 void mouseExited(MouseEvent e)
           
 void mousePressed(MouseEvent e)
           
 void mouseReleased(MouseEvent e)
           
 void removeAction(ComponentAction action)
          Removes an action
 void setVisualComponent(Component component)
           
 
Methods inherited from class org.globus.cog.gui.grapheditor.AbstractRenderer
dispose, getComponent, getRootNode, propertyChange, setComponent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.globus.cog.gui.grapheditor.ComponentRenderer
dispose, getComponent, setComponent
 

Constructor Detail

AbstractSwingRenderer

public AbstractSwingRenderer()
Method Detail

getVisualComponent

public Component getVisualComponent()
Specified by:
getVisualComponent in interface SwingComponentRenderer

setVisualComponent

public void setVisualComponent(Component component)
Specified by:
setVisualComponent in interface SwingComponentRenderer

mouseClicked

public void mouseClicked(MouseEvent e)
Specified by:
mouseClicked in interface MouseListener

mousePressed

public void mousePressed(MouseEvent e)
Specified by:
mousePressed in interface MouseListener

mouseReleased

public void mouseReleased(MouseEvent e)
Specified by:
mouseReleased in interface MouseListener

mouseEntered

public void mouseEntered(MouseEvent e)
Specified by:
mouseEntered in interface MouseListener

mouseExited

public void mouseExited(MouseEvent e)
Specified by:
mouseExited in interface MouseListener

getMenu

public JMenu getMenu()

addAction

public void addAction(ComponentAction action)
Description copied from interface: SwingComponentRenderer
Adds an action to this component. An action represents something that can be performed on this component. In the swing target actions are rendered in a pop-up menu.

Specified by:
addAction in interface SwingComponentRenderer

getActions

public List getActions()
Description copied from interface: SwingComponentRenderer
Returns a list of actions that were added to this component.

Specified by:
getActions in interface SwingComponentRenderer

getAction

public ComponentAction getAction(String name)
Description copied from interface: SwingComponentRenderer
Returns an action with the name specified by the name parameter

Specified by:
getAction in interface SwingComponentRenderer

removeAction

public void removeAction(ComponentAction action)
Description copied from interface: SwingComponentRenderer
Removes an action

Specified by:
removeAction in interface SwingComponentRenderer

actionPerformed

public void actionPerformed(ActionEvent e)
Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class AbstractRenderer

event

public void event(EventObject e)
Specified by:
event in interface EventConsumer