/// <summary> /// Sets the source and target of the given edge in a single atomic change. /// </summary> /// <param name="model">Model that contains the graph.</param> /// <param name="edge">Cell that specifies the edge.</param> /// <param name="source">Cell that specifies the new source terminal.</param> /// <param name="target">Cell that specifies the new target terminal.</param> public static void SetTerminals(mxIGraphModel model, Object edge, Object source, Object target) { model.BeginUpdate(); try { model.SetTerminal(edge, source, true); model.SetTerminal(edge, target, false); } finally { model.EndUpdate(); } }