for (Object obj : graph.getChildEdges(parent)) {
if (obj instanceof mxCell) {
mxCell cell = (mxCell) obj;
SimpleEdge se = new SimpleEdge(vertexes.get(cell.getSource()), vertexes.get(cell.getTarget()));
se.setProperty("id", cell.getId());
sg.addEdge(se);
}
}
MultiLayerLayouter.layout(sg);
mxCell someCell = ((mxCell)vertexes.keySet().toArray()[0]);