Beispiel #1
0
 public VisualNode getOppositeNode(VisualNode node) {
   if (targetNode == node) {
     return sourceNode;
   }
   if (sourceNode == node) {
     return targetNode;
   }
   throw new IllegalArgumentException(
       "Node '"
           + node.getLabel()
           + "' is neither the source nor the target node of the edge '"
           + getLabel()
           + "'");
 }
Beispiel #2
0
 public String getLabel() {
   return sourceNode.getLabel() + "  -->  " + targetNode.getLabel();
 }