Class CreateConnectionRequest

java.lang.Object
org.eclipse.gef.Request
org.eclipse.gef.requests.CreateRequest
org.eclipse.gef.requests.CreateConnectionRequest
All Implemented Interfaces:
DropRequest, TargetRequest

public class CreateConnectionRequest extends CreateRequest implements TargetRequest
A Request to create a new Connection.
  • Constructor Details

    • CreateConnectionRequest

      public CreateConnectionRequest()
  • Method Details

    • getSourceEditPart

      public EditPart getSourceEditPart()
      Returns the EditPart that the source end of the connection should be connected to.
      Returns:
      the source EditPart
    • getTargetEditPart

      public EditPart getTargetEditPart()
      Returns the EditPart that the target end of the connection should be connected to.
      Returns:
      the target EditPart
    • getStartCommand

      public Command getStartCommand()
      Returns the start command. This command is only used to pass on information to the target EditPart so it can create the final command.
      Returns:
      the command
    • setSourceEditPart

      public void setSourceEditPart(EditPart part)
      Sets the source of the Connection to the given EditPart.
      Parameters:
      part - the source EditPart
    • setTargetEditPart

      public void setTargetEditPart(EditPart part)
      Sets the target of the Connection to the given EditPart.
      Specified by:
      setTargetEditPart in interface TargetRequest
      Parameters:
      part - the target EditPart
    • setStartCommand

      public void setStartCommand(Command c)
      Sets the start command. This command is only used to pass on information to the target EditPart so it can create the final command.
      Parameters:
      c - the command