Class InsertState

java.lang.Object
jsimgraph.controller.UIStateDefault
jsimgraph.controller.InsertState

public class InsertState extends UIStateDefault
Defines the behaviour of the mouse listener when the UI is in the insert mode
Author:
dekkar (Federico Granata) Date: Jun 13, 2003 Time: 11:50:33 AM
  • Field Details

    • insertClass

      protected String insertClass
  • Constructor Details

    • InsertState

      public InsertState(Mediator mediator)
      creates the insert state
      Parameters:
      mediator -
  • Method Details

    • handlePress

      public void handlePress(MouseEvent e)
      inserts a new vertex in the graph at the point where the mouse is pressed the new vertex is selected & then sets the select status.
      Overrides:
      handlePress in class UIStateDefault
      Parameters:
      e - mouse press event
    • handleEnter

      public void handleEnter(MouseEvent e)
      Overrides:
      handleEnter in class UIStateDefault
    • setInsertClass

      public void setInsertClass(String className)
      set vertex, it is used to change the vertex tht will be inserted at next press mouse event
      Parameters:
      className - of component to be inserted Bertoli Marco