public class InsertEdgeCommand extends AbstractTransaction
commandManager, committed
version
Constructor and Description |
---|
InsertEdgeCommand(AbstractLocation source,
int x,
int y)
Constructor
|
Modifier and Type | Method and Description |
---|---|
void |
addNail(int x,
int y)
Add nail that the graphical layout of the edge.
|
void |
commit()
Commit the transaction.
|
void |
commit(AbstractLocation target)
Commit setting of the destination of this edge
|
void |
commitBranchPoint(int x,
int y)
Commit the branch point
|
void |
commitLocation(int x,
int y)
Commit the location
|
protected void |
doCancel() |
protected void |
doExecute() |
protected void |
doUndo() |
Element |
getModifiedElement() |
AbstractLocation |
getSource()
Get the source of the edge
|
AbstractLocation |
getTarget()
Get the target of the edge
|
boolean |
hasNails()
Does the edge has nails
|
void |
move(int x,
int y) |
cancel, execute, undo
getVersion, setVersion
public InsertEdgeCommand(AbstractLocation source, int x, int y)
source
- - The source locationx
- - The x value of the edgey
- - The y value of the edgepublic void addNail(int x, int y)
x
- - The x value of the edgey
- - The y value of the edgepublic void move(int x, int y)
move
in class AbstractTransaction
public void commitLocation(int x, int y)
x
- - The x value of the edgey
- - The y value of the edgepublic void commitBranchPoint(int x, int y)
x
- - The x value of the edgey
- - The y value of the edgepublic void commit(AbstractLocation target)
target
- - The locationpublic boolean hasNails()
public AbstractLocation getSource()
public AbstractLocation getTarget()
public void commit()
AbstractTransaction
commit
in class AbstractTransaction
protected void doCancel()
doCancel
in class AbstractTransaction
protected void doExecute()
doExecute
in class AbstractTransaction
protected void doUndo()
doUndo
in class AbstractTransaction
public Element getModifiedElement()
Copyright © 2014 Uppsala University and Aalborg University. All Rights Reserved.