}
AbstractNode srcNode = treeStructure.getNodeAt(source);
AbstractNode destNode = treeStructure.getNodeAt(target);
AbstractEdge edge;
if (ELEMENT_EDGES_PROPER.equalsIgnoreCase(name)) {
edge = new ProperEdgeImpl(id, srcNode, destNode);
} else if (ELEMENT_EDGES_MIXED.equalsIgnoreCase(name)) {
edge = new MixedEdgeImpl(id, srcNode, destNode, directed);
} else {
edge = new SelfLoopImpl(id, srcNode);
}