Pair<Map<Vertex, RectangularShape>, Map<Edge,Pair<RectangularShape,PolyLine>>> layout;
if (skipEdgeLabels)
{
layout = JungGraphBoostUtils.layoutGraphWithoutEdgeLabels(graph,
FunctionFactory.concatenation( new FunctionByMap( vertexComponentMap), ReflectionFunctions.createInvokeMethod("getPreferredSize"), distanceChanger),
context
);
}
else
layout = JungGraphBoostUtils.layoutGraph(graph,
FunctionFactory.concatenation( new FunctionByMap( vertexComponentMap), ReflectionFunctions.createInvokeMethod("getPreferredSize"), distanceChanger),
FunctionFactory.concatenation(new FunctionByMap( edgeLabelComponentMap), ReflectionFunctions.createInvokeMethod("getPreferredSize"), distanceChanger),
context
);
edgePositions = layout.getSecond();
ArrayList<RectangularShape> componentShapes = new ArrayList<RectangularShape>();