org.objectweb.fractal.gui.graph.control
Class SelectTool

java.lang.Object
  extended byorg.objectweb.fractal.gui.graph.control.EmptyGraphViewListener
      extended byorg.objectweb.fractal.gui.graph.control.SelectTool
All Implemented Interfaces:
org.objectweb.fractal.api.control.BindingController, GraphViewListener

public class SelectTool
extends EmptyGraphViewListener
implements org.objectweb.fractal.api.control.BindingController

A controller component to select, move and resize components. This controller component modifies a graph model, in reaction to events emited by a graph view.


Field Summary
static java.lang.String CONFIGURATION_BINDING
          A mandatory client interface bound to a configuration model.
static java.lang.String GRAPH_BINDING
          A mandatory client interface bound to a graph model.
static java.lang.String SELECTION_BINDING
          A mandatory client interface bound to a selection model.
static java.lang.String TOOLS_BINDING
          A mandatory client interface bound to a tools model.
 
Constructor Summary
SelectTool()
          Constructs a new SelectTool component.
 
Method Summary
 void bindFc(java.lang.String clientItfName, java.lang.Object serverItf)
           
 java.lang.String[] listFc()
           
 java.lang.Object lookupFc(java.lang.String clientItfName)
           
 void mouseClicked(java.awt.event.MouseEvent e, ComponentPart p)
          Notifies this listener that the mouse has been clicked.
 void mouseDragged(java.awt.event.MouseEvent e)
          Notifies this listener that the mouse has been dragged in the graph view.
 void mouseMoved(java.awt.event.MouseEvent e, ComponentPart p)
          Notifies this listener that the mouse has mouved in the graph view.
 void mousePressed(java.awt.event.MouseEvent e, ComponentPart p)
          Notifies this listener that the mouse has been pressed.
 void mouseReleased(java.awt.event.MouseEvent e, ComponentPart p)
          Notifies this listener that the mouse has been released.
 void unbindFc(java.lang.String clientItfName)
           
 void viewChanged()
          Notifies this listener that the model represented by the view has changed.
 
Methods inherited from class org.objectweb.fractal.gui.graph.control.EmptyGraphViewListener
mouseEntered, mouseExited
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TOOLS_BINDING

public static final java.lang.String TOOLS_BINDING
A mandatory client interface bound to a tools model. This model is used to know if this tool is the currently selected tool or not.

See Also:
Constant Field Values

CONFIGURATION_BINDING

public static final java.lang.String CONFIGURATION_BINDING
A mandatory client interface bound to a configuration model. When the user double clicks on a componnt, this tools changes the root component of this configuration to the previous component.

See Also:
Constant Field Values

GRAPH_BINDING

public static final java.lang.String GRAPH_BINDING
A mandatory client interface bound to a graph model. This is the graph model that is used to move and resize the components.

See Also:
Constant Field Values

SELECTION_BINDING

public static final java.lang.String SELECTION_BINDING
A mandatory client interface bound to a selection model. This model is used to select components or interfaces, or to know the component that must be moved or resized.

See Also:
Constant Field Values
Constructor Detail

SelectTool

public SelectTool()
Constructs a new SelectTool component.

Method Detail

listFc

public java.lang.String[] listFc()
Specified by:
listFc in interface org.objectweb.fractal.api.control.BindingController

lookupFc

public java.lang.Object lookupFc(java.lang.String clientItfName)
Specified by:
lookupFc in interface org.objectweb.fractal.api.control.BindingController

bindFc

public void bindFc(java.lang.String clientItfName,
                   java.lang.Object serverItf)
Specified by:
bindFc in interface org.objectweb.fractal.api.control.BindingController

unbindFc

public void unbindFc(java.lang.String clientItfName)
Specified by:
unbindFc in interface org.objectweb.fractal.api.control.BindingController

viewChanged

public void viewChanged()
Description copied from interface: GraphViewListener
Notifies this listener that the model represented by the view has changed.

Specified by:
viewChanged in interface GraphViewListener
Overrides:
viewChanged in class EmptyGraphViewListener

mousePressed

public void mousePressed(java.awt.event.MouseEvent e,
                         ComponentPart p)
Description copied from interface: GraphViewListener
Notifies this listener that the mouse has been pressed.

Specified by:
mousePressed in interface GraphViewListener
Overrides:
mousePressed in class EmptyGraphViewListener

mouseReleased

public void mouseReleased(java.awt.event.MouseEvent e,
                          ComponentPart p)
Description copied from interface: GraphViewListener
Notifies this listener that the mouse has been released.

Specified by:
mouseReleased in interface GraphViewListener
Overrides:
mouseReleased in class EmptyGraphViewListener

mouseClicked

public void mouseClicked(java.awt.event.MouseEvent e,
                         ComponentPart p)
Description copied from interface: GraphViewListener
Notifies this listener that the mouse has been clicked.

Specified by:
mouseClicked in interface GraphViewListener
Overrides:
mouseClicked in class EmptyGraphViewListener

mouseDragged

public void mouseDragged(java.awt.event.MouseEvent e)
Description copied from interface: GraphViewListener
Notifies this listener that the mouse has been dragged in the graph view.

Specified by:
mouseDragged in interface GraphViewListener
Overrides:
mouseDragged in class EmptyGraphViewListener

mouseMoved

public void mouseMoved(java.awt.event.MouseEvent e,
                       ComponentPart p)
Description copied from interface: GraphViewListener
Notifies this listener that the mouse has mouved in the graph view.

Specified by:
mouseMoved in interface GraphViewListener
Overrides:
mouseMoved in class EmptyGraphViewListener