org.graffiti.plugins.modes.advanced.selection
Class SelectionTool

java.lang.Object
  extended by java.awt.event.MouseAdapter
      extended by javax.swing.event.MouseInputAdapter
          extended by org.graffiti.plugins.modes.deprecated.AbstractTool
              extended by org.graffiti.plugins.modes.deprecated.AbstractUndoableTool
                  extended by org.graffiti.plugins.modes.advanced.AbstractEditingTool
                      extended by org.graffiti.plugins.modes.advanced.selection.SelectionTool
All Implemented Interfaces:
MouseListener, MouseMotionListener, MouseWheelListener, EventListener, MouseInputListener, ViewListener, FunctionComponent, org.graffiti.plugins.modes.deprecated.Tool, SelectionListener, SessionListener, Undoable

Deprecated.

@Deprecated
public class SelectionTool
extends AbstractEditingTool

An editing-tool for selecting and moving graph-elements. Note: A (the) region is an area of the graph during the process of selecting elements (currently always a rectangle).


Field Summary
static int MOVE_MARKED_ELEMENTS
          Deprecated. move marked elements mode
static int MOVE_ONLY_BEND
          Deprecated. move only bend mode
static int MOVE_ONLY_NODE
          Deprecated. move only node mode
static int RECT
          Deprecated. selection rectangle mode
 
Fields inherited from class org.graffiti.plugins.modes.advanced.AbstractEditingTool
BOTTOM, CENTER, CENTER_HORIZONTAL, CENTER_VERTICAL, DEFAULT, DOWN, LEFT, RIGHT, TOP, UP
 
Constructor Summary
SelectionTool(ToolPlugin toolPlugin, PositionInfo positionInfo)
          Deprecated. Creates a new SelectionTool object.
 
Method Summary
 Set<GraphElementComponent> filterGEComponents(Set<Component> components)
          Deprecated. Filters the GEComponents out of the given Set components
 void filterRectComponents(Set<Component> components, Rectangle rectangle)
          Deprecated. Filters the components, where rectangle intersects.
 Map<String,Attribute> getBendsOfEdge(Edge edge)
          Deprecated. Method that delivers a Map with bends of a certain edge
 Set<Component> getContainerComponents(Container container)
          Deprecated. Returns a set of components in a given container
 Set<GraphElementComponent> getCurrentSelectedElements()
          Deprecated. Returns the currently selected elements
 Set<GraphElement> getFormerSelectedElements()
          Deprecated. Returns the former selected elements
 FunctionAction getFunctionAction(String functionName)
          Deprecated. Returns the FunctionAction of a given function
 GraphElement getGraphElementToMove()
          Deprecated. Returns the graphelement to move
 int getMode()
          Deprecated. Returns the mode of the actual tool
 List<Edge> getMoveEdges()
          Deprecated. Returns the moveNodes
 List<Node> getMoveNodes()
          Deprecated. Returns the moveNodes
 Rectangle getSelectionRectangle()
          Deprecated. Returns the selection rectangle
 boolean isDuring_update_move_bend()
          Deprecated. Returns value of during_update_rotate_bend.
 boolean isDuring_update_move_only_node()
          Deprecated. True if tool is during an move only node update, else false
 boolean isDuring_update_move()
          Deprecated. Returns value of during_update_move.
 void setCurrentSelectedElements(Set<GraphElementComponent> currentSelectedElements)
          Deprecated. Set the currently selected elements.
 void setCurrentSelectRectPosition(Point point)
          Deprecated. Sets the current selection rectangle positiion
 void setDuring_update_move_bend(boolean b)
          Deprecated. Sets the variable during_update_rotate_bend to b.
 void setDuring_update_move_only_node(boolean b)
          Deprecated. Sets the variable during_update_move to b True, if tool is during an update of a graph element.
 void setDuring_update_move(boolean b)
          Deprecated. Sets the variable during_update_move to b True, if tool is during an update of a graph element.
 void setGraphElementToMove(GraphElement graphElement)
          Deprecated. Sets the graphelement to move to graphElement
 void setModeToDefault()
          Deprecated. Sets the mode to default
 void setModeToMoveMarkedElements()
          Deprecated. Sets the mode to move marked elements mode
 void setModeToMoveOnlyBend()
          Deprecated. Sets the mode to move only bend mode
 void setModeToMoveOnlyNode()
          Deprecated. Sets the mode to move only node mode
 void setModeToRect()
          Deprecated. Sets the mode to select rectangle mode
 void setMoveEdges(List<Edge> list)
          Deprecated. Sets the moveEdges to list.
 void setMoveNodes(List<Node> list)
          Deprecated. Sets the list moveNodes to list
 void setStartSelectRectPosition(Point point)
          Deprecated. Sets the start position of the selection rectangle to point
 
Methods inherited from class org.graffiti.plugins.modes.advanced.AbstractEditingTool
activate, addAttributesToMap, addAttributesToMap, afterEvent, beforeEvent, deactivate, fireSelectionChanged, getActiveJComponent, getAttributesMap, getBendCoords, getCooAttNode, getDummySupportViews, getGEMap, getGraph, getNodeCoords, getNodeDims, getNodesUnderMouse, getPositionInfo, getPrefs, getSelection, getSubComponent, getToolPlugin, getTopEdge, getTopEdgeComponent, getTopGEComponent, getTopGraphElement, getTopNode, getTopNodeComponent, getUndoSupport, getViewComponent, getZoomedPosition, isInDefaultMode, isInMultiCommandMode, isMarked, isMarked, isViewListener, mark, mark, mouseDragged, mouseEntered, mouseExited, mouseMoved, nodeAdded, sessionChanged, setAttributesMap, setBendCoords, setNodeCoords, setNodeDims, switchToDefaultMode, switchToMultiCommandMode, unmark, unmark, unmarkAll, viewChanged
 
Methods inherited from class org.graffiti.plugins.modes.deprecated.AbstractUndoableTool
isSelectionListener, isSessionListener, sessionDataChanged, setUndoSupport
 
Methods inherited from class org.graffiti.plugins.modes.deprecated.AbstractTool
displayAsMarked, displayAsMarked, displayAsMarked, displayAsMarked, highlight, isActive, selectionChanged, selectionListChanged, setGraph, setPrefs, unDisplayAsMarked, unDisplayAsMarked, unDisplayAsMarked, unDisplayAsMarked
 
Methods inherited from class java.awt.event.MouseAdapter
mouseClicked, mousePressed, mouseReleased, mouseWheelMoved
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.awt.event.MouseListener
mouseClicked, mousePressed, mouseReleased
 

Field Detail

RECT

public static final int RECT
Deprecated. 
selection rectangle mode

See Also:
Constant Field Values

MOVE_MARKED_ELEMENTS

public static final int MOVE_MARKED_ELEMENTS
Deprecated. 
move marked elements mode

See Also:
Constant Field Values

MOVE_ONLY_NODE

public static final int MOVE_ONLY_NODE
Deprecated. 
move only node mode

See Also:
Constant Field Values

MOVE_ONLY_BEND

public static final int MOVE_ONLY_BEND
Deprecated. 
move only bend mode

See Also:
Constant Field Values
Constructor Detail

SelectionTool

public SelectionTool(ToolPlugin toolPlugin,
                     PositionInfo positionInfo)
Deprecated. 
Creates a new SelectionTool object.

Parameters:
toolPlugin - The given ToolPlugin
positionInfo - The given PositionInfo
Method Detail

getBendsOfEdge

public Map<String,Attribute> getBendsOfEdge(Edge edge)
Deprecated. 
Method that delivers a Map with bends of a certain edge

Parameters:
edge - The given edge
Returns:
A Map with the bends of the edge edge

getContainerComponents

public Set<Component> getContainerComponents(Container container)
Deprecated. 
Returns a set of components in a given container

Parameters:
container - The given Container
Returns:
a set of components in a given container

setCurrentSelectRectPosition

public void setCurrentSelectRectPosition(Point point)
Deprecated. 
Sets the current selection rectangle positiion

Parameters:
point - Position which has to be set to the current selection rectangle position

getCurrentSelectedElements

public Set<GraphElementComponent> getCurrentSelectedElements()
Deprecated. 
Returns the currently selected elements

Returns:
The currently selected elements

setCurrentSelectedElements

public void setCurrentSelectedElements(Set<GraphElementComponent> currentSelectedElements)
Deprecated. 
Set the currently selected elements.

Parameters:
currentSelectedElements - Currently selected elements.

setDuring_update_move

public void setDuring_update_move(boolean b)
Deprecated. 
Sets the variable during_update_move to b True, if tool is during an update of a graph element. Else, false

Parameters:
b - boolean value

isDuring_update_move

public boolean isDuring_update_move()
Deprecated. 
Returns value of during_update_move. True, if tool is during an update of a graph element. Else, false

Returns:
true if an element is updated, false otherwise.

setDuring_update_move_bend

public void setDuring_update_move_bend(boolean b)
Deprecated. 
Sets the variable during_update_rotate_bend to b. True, if tool is during the update move of a bend. Else, false

Parameters:
b - the given boolean value

isDuring_update_move_bend

public boolean isDuring_update_move_bend()
Deprecated. 
Returns value of during_update_rotate_bend. True, if tool is during an update of a bend. Else, false

Returns:
true if bend is updated, false otherwise.

setDuring_update_move_only_node

public void setDuring_update_move_only_node(boolean b)
Deprecated. 
Sets the variable during_update_move to b True, if tool is during an update of a graph element. Else, false

Parameters:
b - boolean value

isDuring_update_move_only_node

public boolean isDuring_update_move_only_node()
Deprecated. 
True if tool is during an move only node update, else false

Returns:
True if tool is during an move only node update, else false

getFormerSelectedElements

public Set<GraphElement> getFormerSelectedElements()
Deprecated. 
Returns the former selected elements

Returns:
the former selected elements

getFunctionAction

public FunctionAction getFunctionAction(String functionName)
Deprecated. 
Returns the FunctionAction of a given function

Specified by:
getFunctionAction in interface FunctionComponent
Overrides:
getFunctionAction in class AbstractEditingTool
Parameters:
functionName - Given name of the function
Returns:
The action of the function (if not exists: then null)

setGraphElementToMove

public void setGraphElementToMove(GraphElement graphElement)
Deprecated. 
Sets the graphelement to move to graphElement

Parameters:
graphElement -

getGraphElementToMove

public GraphElement getGraphElementToMove()
Deprecated. 
Returns the graphelement to move

Returns:
the graphelement to move

getMode

public int getMode()
Deprecated. 
Returns the mode of the actual tool

Overrides:
getMode in class AbstractEditingTool
Returns:
the mode of the actual tool

setModeToDefault

public void setModeToDefault()
Deprecated. 
Sets the mode to default

Overrides:
setModeToDefault in class AbstractEditingTool

setModeToMoveMarkedElements

public void setModeToMoveMarkedElements()
Deprecated. 
Sets the mode to move marked elements mode


setModeToMoveOnlyBend

public void setModeToMoveOnlyBend()
Deprecated. 
Sets the mode to move only bend mode


setModeToMoveOnlyNode

public void setModeToMoveOnlyNode()
Deprecated. 
Sets the mode to move only node mode


setModeToRect

public void setModeToRect()
Deprecated. 
Sets the mode to select rectangle mode


setMoveEdges

public void setMoveEdges(List<Edge> list)
Deprecated. 
Sets the moveEdges to list.

Parameters:
list - The given List of edges.

getMoveEdges

public List<Edge> getMoveEdges()
Deprecated. 
Returns the moveNodes

Returns:
the moveNodes

setMoveNodes

public void setMoveNodes(List<Node> list)
Deprecated. 
Sets the list moveNodes to list

Parameters:
list - The given List of nodes

getMoveNodes

public List<Node> getMoveNodes()
Deprecated. 
Returns the moveNodes

Returns:
the moveNodes

getSelectionRectangle

public Rectangle getSelectionRectangle()
Deprecated. 
Returns the selection rectangle

Returns:
The selection rectangle

setStartSelectRectPosition

public void setStartSelectRectPosition(Point point)
Deprecated. 
Sets the start position of the selection rectangle to point

Parameters:
point - the new start position of the selection rectangle

filterGEComponents

public Set<GraphElementComponent> filterGEComponents(Set<Component> components)
Deprecated. 
Filters the GEComponents out of the given Set components

Parameters:
components - The given Set.

filterRectComponents

public void filterRectComponents(Set<Component> components,
                                 Rectangle rectangle)
Deprecated. 
Filters the components, where rectangle intersects.

Parameters:
components - The given components
rectangle - The given rectangle


Generated at 2012-05-30 11:01:25 PM CEST