<divid=Content><divclass="CClass"><divclass=CTopicid=MainTopic><h1class=CTitle><aname="mxGraphModel"></a>mxGraphModel</h1><divclass=CBody><p>Extends <ahref="../util/mxEventSource-js.html#mxEventSource"class=LClassid=link196onMouseOver="ShowTip(event, 'tt1', 'link196')"onMouseOut="HideTip('tt1')">mxEventSource</a> to implement a graph model. The graph model acts as a wrapper around the cells which are in charge of storing the actual graph datastructure. The model acts as a transactional wrapper with event notification for all changes, whereas the cells contain the atomic operations for updating the actual datastructure.</p><h4class=CHeading>Layers</h4><p>The cell hierarchy in the model must have a top-level root cell which contains the layers (typically one default layer), which in turn contain the top-level cells of the layers. This means each cell is contained in a layer. If no layers are required, then all new cells should be added to the default layer.</p><p>Layers are useful for hiding and showing groups of cells, or for placing groups of cells on top of other cells in the display. To identify a layer, the <ahref="#mxGraphModel.isLayer"class=LFunctionid=link197onMouseOver="ShowTip(event, 'tt31', 'link197')"onMouseOut="HideTip('tt31')">isLayer</a> function is used. It returns true if the parent of the given cell is the root of the model.</p><h4class=CHeading>Events</h4><p>See events section for more details. There is a new set of events for tracking transactional changes as they happen. The events are called startEdit for the initial beginUpdate, executed for each executed change and endEdit for the terminal endUpdate. The executed event contains a property called change which represents the change after execution.</p><h4class=CHeading>Encoding the model</h4><h4class=CHeading>To encode a graph model, use the following code</h4><blockquote><preclass="prettyprint">var enc = new mxCodec();
var node = enc.encode(graph.getModel());</pre></blockquote><p>This will create an XML node that contains all the model information.</p><h4class=CHeading>Encoding and decoding changes</h4><p>For the encoding of changes, a graph model listener is required that encodes each change from the given array of changes.</p><blockquote><preclass="prettyprint">model.addListener(mxEvent.CHANGE, function(sender, evt)
{
var changes = evt.getProperty('edit').changes;
var nodes = [];
var codec = new mxCodec();
for (var i = 0; i < changes.length; i++)
{
nodes.push(codec.encode(changes[i]));
}
// do something with the nodes
});</pre></blockquote><p>For the decoding and execution of changes, the codec needs a lookup function that allows it to resolve cell IDs as follows:</p><blockquote><preclass="prettyprint">var codec = new mxCodec();
codec.lookup = function(id)
{
return model.getCell(id);
}</pre></blockquote><p>For each encoded change (represented by a node), the following code can be used to carry out the decoding and create a change object.</p><blockquote><preclass="prettyprint">var changes = [];
var change = codec.decode(node);
change.model = model;
change.execute();
changes.push(change);</pre></blockquote><p>The changes can then be dispatched using the model as follows.</p><blockquote><preclass="prettyprint">var edit = new mxUndoableEdit(model, false);
'edit', edit, 'changes', changes));</pre></blockquote><!--START_ND_SUMMARY--><divclass=Summary><divclass=STitle>Summary</div><divclass=SBorder><tableborder=0cellspacing=0cellpadding=0class=STable><trclass="SMain"><tdclass=SEntry><ahref="#mxGraphModel">mxGraphModel</a></td><tdclass=SDescription>Extends <ahref="../util/mxEventSource-js.html#mxEventSource"class=LClassid=link1onMouseOver="ShowTip(event, 'tt1', 'link1')"onMouseOut="HideTip('tt1')">mxEventSource</a> to implement a graph model. </td></tr><trclass="SGroup SIndent1"><tdclass=SEntry><ahref="#mxGraphModel.Events">Events</a></td><tdclass=SDescription></td></tr><trclass="SEvent SIndent2 SMarked"><tdclass=SEntry><ahref="#mxGraphModel.mxEvent.CHANGE">mxEvent.<wbr>CHANGE</a></td><tdclass=SDescription>Fires when an undoable edit is dispatched. </td></tr><trclass="SEvent SIndent2"><tdclass=SEntry><ahref="#mxGraphModel.mxEvent.NOTIFY">mxEvent.<wbr>NOTIFY</a></td><tdclass=SDescription>Same as <ahref="#mxGraphModel.mxEvent.CHANGE"class=LEventid=link2onMouseOver="ShowTip(event, 'tt2', 'link2')"onMouseOut="HideTip('tt2')">mxEvent.CHANGE</a>, this event can be used for classes that need to implement a sync mechanism between this model and, say, a remote model. </td></tr><trclass="SEvent SIndent2 SMarked"><tdclass=SEntry><ahref="#mxGraphModel.mxEvent.EXECUTE">mxEvent.<wbr>EXECUTE</a></td><tdclass=SDescription>Fires between begin- and endUpdate and after an atomic change was executed in the model. </td></tr><trclass="SEvent SIndent2"><tdclass=SEntry><ahref="#mxGraphModel.mxEvent.EXECUTED">mxEvent.<wbr>EXECUTED</a></td><tdclass=SDescription>Fires between START_EDIT and END_EDIT after an atomic change was executed. </td></tr><trclass="SEvent SIndent2 SMarked"><tdclass=SEntry><ahref="#mxGraphModel.mxEvent.BEGIN_UPDATE">mxEvent.<wbr>BEGIN_UPDATE</a></td><tdclass=SDescription>Fires after the <ahref="#mxGraphModel.updateLevel"class=LVariableid=link3onMouseOver="ShowTip(event, 'tt3', 'link3')"onMouseOut="HideTip('tt3')">updateLevel</a> was incremented in <ahref="#mxGraphModel.beginUpdate"class=LFunctionid=link4onMouseOver="ShowTip(event, 'tt4', 'link4')"onMouseOut="HideTip('tt4')">beginUpdate</a>. </td></tr><trclass="SEvent SIndent2"><tdclass=SEntry><ahref="#mxGraphModel.mxEvent.START_EDIT">mxEvent.<wbr>START_EDIT</a></td><tdclass=SDescription>Fires after the <ahref="#mxGraphModel.updateLevel"class=LVariableid=link5onMouseOver="ShowTip(event, 'tt3', 'link5')"onMouseOut="HideTip('tt3')">updateLevel</a> was changed from 0 to 1. </td></tr><trclass="SEvent SIndent2 SMarked"><tdclass=SEntry><ahref="#mxGraphModel.mxEvent.END_UPDATE">mxEvent.<wbr>END_UPDATE</a></td><tdclass=SDescription>Fires after the <ahref="#mxGraphModel.updateLevel"class=LVariableid=link6onMouseOver="ShowTip(event, 'tt3', 'link6')"onMouseOut="HideTip('tt3')">updateLevel</a> was decreased in <ahref="#mxGraphModel.endUpdate"class=LFunctionid=link7onMouseOver="ShowTip(event, 'tt5', 'link7')"onMouseOut="HideTip('tt5')">endUpdate</a> but before any notification or change dispatching. </td></tr><trclass="SEvent SIndent2"><tdclass=SEntry><ahref="#mxGraphModel.mxEvent.END_EDIT">mxEvent.<wbr>END_EDIT</a></td><tdclass=SDescription>Fires after the <ahref="#mxGraphModel.updateLevel"class=LVariableid=link8onMouseOver="ShowTip(event, 'tt3', 'link8')"onMouseOut="HideTip('tt3')">updateLevel</a> was changed from 1 to 0. </td></tr><trclass="SEvent SIndent2 SMarked"><tdclass=SEntry><ahref="#mxGraphModel.mxEvent.BEFORE_UNDO">mxEvent.<wbr>BEFORE_UNDO</a></td><tdclass=SDescription>Fires before the change is dispatched after the update level has reached 0 in <ahref="#mxGraphModel.endUpdate"class=LFunctionid=link9onMouseOver="ShowTip(event, 'tt5', 'link9')"onMouseOut="HideTip('tt5')">endUpdate</a>. </td></tr><trclass="SEvent SIndent2"><tdclass=SEntry><ahref="#mxGraphModel.mxEvent.UNDO">mxEvent.UNDO</a></td><tdclass=SDescription>Fires after the change was dispatched in <ahref="#mxGraphModel.endUpdate"class=LFunctionid=link10onM
<divclass="CEvent"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.mxEvent.CHANGE"></a>mxEvent.<wbr>CHANGE</h3><divclass=CBody><p>Fires when an undoable edit is dispatched. The <code>edit</code> property contains the <ahref="../util/mxUndoableEdit-js.html#mxUndoableEdit"class=LClassid=link198onMouseOver="ShowTip(event, 'tt100', 'link198')"onMouseOut="HideTip('tt100')">mxUndoableEdit</a>. The <code>changes</code> property contains the array of atomic changes inside the undoable edit. The changes property is <strong>deprecated</strong>, please use edit.changes instead.</p><h4class=CHeading>Example</h4><h4class=CHeading>For finding newly inserted cells, the following code can be used</h4><blockquote><preclass="prettyprint">graph.model.addListener(mxEvent.CHANGE, function(sender, evt)
<divclass="CEvent"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.mxEvent.NOTIFY"></a>mxEvent.<wbr>NOTIFY</h3><divclass=CBody><p>Same as <ahref="#mxGraphModel.mxEvent.CHANGE"class=LEventid=link199onMouseOver="ShowTip(event, 'tt2', 'link199')"onMouseOut="HideTip('tt2')">mxEvent.CHANGE</a>, this event can be used for classes that need to implement a sync mechanism between this model and, say, a remote model. In such a setup, only local changes should trigger a notify event and all changes should trigger a change event.</p></div></div></div>
<divclass="CEvent"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.mxEvent.EXECUTE"></a>mxEvent.<wbr>EXECUTE</h3><divclass=CBody><p>Fires between begin- and endUpdate and after an atomic change was executed in the model. The <code>change</code> property contains the atomic change that was executed.</p></div></div></div>
<divclass="CEvent"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.mxEvent.EXECUTED"></a>mxEvent.<wbr>EXECUTED</h3><divclass=CBody><p>Fires between START_EDIT and END_EDIT after an atomic change was executed. The <code>change</code> property contains the change that was executed.</p></div></div></div>
<divclass="CEvent"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.mxEvent.BEGIN_UPDATE"></a>mxEvent.<wbr>BEGIN_UPDATE</h3><divclass=CBody><p>Fires after the <ahref="#mxGraphModel.updateLevel"class=LVariableid=link200onMouseOver="ShowTip(event, 'tt3', 'link200')"onMouseOut="HideTip('tt3')">updateLevel</a> was incremented in <ahref="#mxGraphModel.beginUpdate"class=LFunctionid=link201onMouseOver="ShowTip(event, 'tt4', 'link201')"onMouseOut="HideTip('tt4')">beginUpdate</a>. This event contains no properties.</p></div></div></div>
<divclass="CEvent"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.mxEvent.START_EDIT"></a>mxEvent.<wbr>START_EDIT</h3><divclass=CBody><p>Fires after the <ahref="#mxGraphModel.updateLevel"class=LVariableid=link202onMouseOver="ShowTip(event, 'tt3', 'link202')"onMouseOut="HideTip('tt3')">updateLevel</a> was changed from 0 to 1. This event contains no properties.</p></div></div></div>
<divclass="CEvent"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.mxEvent.END_UPDATE"></a>mxEvent.<wbr>END_UPDATE</h3><divclass=CBody><p>Fires after the <ahref="#mxGraphModel.updateLevel"class=LVariableid=link203onMouseOver="ShowTip(event, 'tt3', 'link203')"onMouseOut="HideTip('tt3')">updateLevel</a> was decreased in <ahref="#mxGraphModel.endUpdate"class=LFunctionid=link204onMouseOver="ShowTip(event, 'tt5', 'link204')"onMouseOut="HideTip('tt5')">endUpdate</a> but before any notification or change dispatching. The <code>edit</code> property contains the <ahref="#mxGraphModel.currentEdit"class=LVariableid=link205onMouseOver="ShowTip(event, 'tt15', 'link205')"onMouseOut="HideTip('tt15')">currentEdit</a>.</p></div></div></div>
<divclass="CEvent"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.mxEvent.END_EDIT"></a>mxEvent.<wbr>END_EDIT</h3><divclass=CBody><p>Fires after the <ahref="#mxGraphModel.updateLevel"class=LVariableid=link206onMouseOver="ShowTip(event, 'tt3', 'link206')"onMouseOut="HideTip('tt3')">updateLevel</a> was changed from 1 to 0. This event contains no properties.</p></div></div></div>
<divclass="CEvent"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.mxEvent.BEFORE_UNDO"></a>mxEvent.<wbr>BEFORE_UNDO</h3><divclass=CBody><p>Fires before the change is dispatched after the update level has reached 0 in <ahref="#mxGraphModel.endUpdate"class=LFunctionid=link207onMouseOver="ShowTip(event, 'tt5', 'link207')"onMouseOut="HideTip('tt5')">endUpdate</a>. The <code>edit</code> property contains the <curreneEdit>.</p></div></div></div>
<divclass="CEvent"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.mxEvent.UNDO"></a>mxEvent.UNDO</h3><divclass=CBody><p>Fires after the change was dispatched in <ahref="#mxGraphModel.endUpdate"class=LFunctionid=link208onMouseOver="ShowTip(event, 'tt5', 'link208')"onMouseOut="HideTip('tt5')">endUpdate</a>. The <code>edit</code> property contains the <ahref="#mxGraphModel.currentEdit"class=LVariableid=link209onMouseOver="ShowTip(event, 'tt15', 'link209')"onMouseOut="HideTip('tt15')">currentEdit</a>.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.mxGraphModel"></a>mxGraphModel</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>function mxGraphModel(</td><tdclass="PParameter prettyprint "nowrap>root</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Constructs a new graph model. If no root is specified then a new root <ahref="mxCell-js.html#mxCell"class=LClassid=link210onMouseOver="ShowTip(event, 'tt22', 'link210')"onMouseOut="HideTip('tt22')">mxCell</a> with a default layer is created.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>root</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link211onMouseOver="ShowTip(event, 'tt22', 'link211')"onMouseOut="HideTip('tt22')">mxCell</a> that represents the root cell.</td></tr></table></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.root"></a>root</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.root</td></tr></table></blockquote><p>Holds the root cell, which in turn contains the cells that represent the layers of the diagram as child cells. That is, the actual elements of the diagram are supposed to live in the third generation of cells and below.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.cells"></a>cells</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.cells</td></tr></table></blockquote><p>Maps from Ids to cells.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.maintainEdgeParent"></a>maintainEdgeParent</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.maintainEdgeParent</td></tr></table></blockquote><p>Specifies if edges should automatically be moved into the nearest common ancestor of their terminals. Default is true.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.ignoreRelativeEdgeParent"></a>ignoreRelativeEdgeParent</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.ignoreRelativeEdgeParent</td></tr></table></blockquote><p>Specifies if relative edge parents should be ignored for finding the nearest common ancestors of an edge’s terminals. Default is true.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.createIds"></a>createIds</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.createIds</td></tr></table></blockquote><p>Specifies if the model should automatically create Ids for new cells. Default is true.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.prefix"></a>prefix</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.prefix</td></tr></table></blockquote><p>Defines the prefix of new Ids. Default is an empty string.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.postfix"></a>postfix</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.postfix</td></tr></table></blockquote><p>Defines the postfix of new Ids. Default is an empty string.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.nextId"></a>nextId</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.nextId</td></tr></table></blockquote><p>Specifies the next Id to be created. Initial value is 0.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.currentEdit"></a>currentEdit</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.currentEdit</td></tr></table></blockquote><p>Holds the changes for the current transaction. If the transaction is closed then a new object is created for this variable using <ahref="#mxGraphModel.createUndoableEdit"class=LFunctionid=link212onMouseOver="ShowTip(event, 'tt99', 'link212')"onMouseOut="HideTip('tt99')">createUndoableEdit</a>.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.updateLevel"></a>updateLevel</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.updateLevel</td></tr></table></blockquote><p>Counter for the depth of nested transactions. Each call to <ahref="#mxGraphModel.beginUpdate"class=LFunctionid=link213onMouseOver="ShowTip(event, 'tt4', 'link213')"onMouseOut="HideTip('tt4')">beginUpdate</a> will increment this number and each call to <ahref="#mxGraphModel.endUpdate"class=LFunctionid=link214onMouseOver="ShowTip(event, 'tt5', 'link214')"onMouseOut="HideTip('tt5')">endUpdate</a> will decrement it. When the counter reaches 0, the transaction is closed and the respective events are fired. Initial value is 0.</p></div></div></div>
<divclass="CVariable"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.endingUpdate"></a>endingUpdate</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.endingUpdate</td></tr></table></blockquote><p>True if the program flow is currently inside endUpdate.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.clear"></a>clear</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.clear = function()</td></tr></table></blockquote><p>Sets a new root using <ahref="#mxGraphModel.createRoot"class=LFunctionid=link215onMouseOver="ShowTip(event, 'tt18', 'link215')"onMouseOut="HideTip('tt18')">createRoot</a>.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.createRoot"></a>createRoot</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.createRoot = function()</td></tr></table></blockquote><p>Creates a new root cell with a default layer (child 0).</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getCell"></a>getCell</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getCell = function(</td><tdclass="PParameter prettyprint "nowrap>id</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the <ahref="mxCell-js.html#mxCell"class=LClassid=link218onMouseOver="ShowTip(event, 'tt22', 'link218')"onMouseOut="HideTip('tt22')">mxCell</a> for the specified Id or null if no cell can be found for the given Id.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>id</td><tdclass=CDLDescription>A string representing the Id of the cell.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.filterCells"></a>filterCells</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.filterCells = function(</td><tdclass="PParameter prettyprint "nowrap>cells,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>filter</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the cells from the given array where the given filter function returns true.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getDescendants"></a>getDescendants</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getDescendants = function(</td><tdclass="PParameter prettyprint "nowrap>parent</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns all descendants of the given cell and the cell itself in an array.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>parent</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link219onMouseOver="ShowTip(event, 'tt22', 'link219')"onMouseOut="HideTip('tt22')">mxCell</a> whose descendants should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.filterDescendants"></a>filterDescendants</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.filterDescendants = function(</td><tdclass="PParameter prettyprint "nowrap>filter,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>parent</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Visits all cells recursively and applies the specified filter function to each cell. If the function returns true then the cell is added to the resulting array. The parent and result paramters are optional. If parent is not specified then the recursion starts at <ahref="#mxGraphModel.root"class=LVariableid=link220onMouseOver="ShowTip(event, 'tt7', 'link220')"onMouseOut="HideTip('tt7')">root</a>.</p><h4class=CHeading>Example</h4><p>The following example extracts all vertices from a given model:</p><blockquote><preclass="prettyprint">var filter = function(cell)
var vertices = model.filterDescendants(filter);</pre></blockquote><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>filter</td><tdclass=CDLDescription>JavaScript function that takes an <ahref="mxCell-js.html#mxCell"class=LClassid=link221onMouseOver="ShowTip(event, 'tt22', 'link221')"onMouseOut="HideTip('tt22')">mxCell</a> as an argument and returns a boolean.</td></tr><tr><tdclass=CDLEntry>parent</td><tdclass=CDLDescription>Optional <ahref="mxCell-js.html#mxCell"class=LClassid=link222onMouseOver="ShowTip(event, 'tt22', 'link222')"onMouseOut="HideTip('tt22')">mxCell</a> that is used as the root of the recursion.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getRoot"></a>getRoot</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getRoot = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the root of the model or the topmost parent of the given cell.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription>Optional <ahref="mxCell-js.html#mxCell"class=LClassid=link223onMouseOver="ShowTip(event, 'tt22', 'link223')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the child.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.setRoot"></a>setRoot</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setRoot = function(</td><tdclass="PParameter prettyprint "nowrap>root</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the <ahref="#mxGraphModel.root"class=LVariableid=link224onMouseOver="ShowTip(event, 'tt7', 'link224')"onMouseOut="HideTip('tt7')">root</a> of the model using <ahref="#mxRootChange"class=LClassid=link225onMouseOver="ShowTip(event, 'tt28', 'link225')"onMouseOut="HideTip('tt28')">mxRootChange</a> and adds the change to the current transaction. This resets all datastructures in the model and is the preferred way of clearing an existing model. Returns the new root.</p><h4class=CHeading>Example</h4><blockquote><preclass="prettyprint">var root = new mxCell();
model.setRoot(root);</pre></blockquote><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>root</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link226onMouseOver="ShowTip(event, 'tt22', 'link226')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new root.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.rootChanged"></a>rootChanged</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.rootChanged = function(</td><tdclass="PParameter prettyprint "nowrap>root</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to change the root of the model and update the internal datastructures, such as <ahref="#mxGraphModel.cells"class=LVariableid=link227onMouseOver="ShowTip(event, 'tt8', 'link227')"onMouseOut="HideTip('tt8')">cells</a> and <ahref="#mxGraphModel.nextId"class=LVariableid=link228onMouseOver="ShowTip(event, 'tt14', 'link228')"onMouseOut="HideTip('tt14')">nextId</a>. Returns the previous root.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>root</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link229onMouseOver="ShowTip(event, 'tt22', 'link229')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new root.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.isRoot"></a>isRoot</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isRoot = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the given cell is the root of the model and a non-null value.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link230onMouseOver="ShowTip(event, 'tt22', 'link230')"onMouseOut="HideTip('tt22')">mxCell</a> that represents the possible root.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.isLayer"></a>isLayer</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isLayer = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if <ahref="#mxGraphModel.isRoot"class=LFunctionid=link231onMouseOver="ShowTip(event, 'tt30', 'link231')"onMouseOut="HideTip('tt30')">isRoot</a> returns true for the parent of the given cell.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link232onMouseOver="ShowTip(event, 'tt22', 'link232')"onMouseOut="HideTip('tt22')">mxCell</a> that represents the possible layer.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.isAncestor"></a>isAncestor</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isAncestor = function(</td><tdclass="PParameter prettyprint "nowrap>parent,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>child</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the given parent is an ancestor of the given child.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>parent</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link233onMouseOver="ShowTip(event, 'tt22', 'link233')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the parent.</td></tr><tr><tdclass=CDLEntry>child</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link234onMouseOver="ShowTip(event, 'tt22', 'link234')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the child.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.contains"></a>contains</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.contains = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the model contains the given <ahref="mxCell-js.html#mxCell"class=LClassid=link235onMouseOver="ShowTip(event, 'tt22', 'link235')"onMouseOut="HideTip('tt22')">mxCell</a>.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link236onMouseOver="ShowTip(event, 'tt22', 'link236')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getParent"></a>getParent</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getParent = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the parent of the given cell.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link237onMouseOver="ShowTip(event, 'tt22', 'link237')"onMouseOut="HideTip('tt22')">mxCell</a> whose parent should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.add"></a>add</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.add = function(</td><tdclass="PParameter prettyprint "nowrap>parent,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>child,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>index</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Adds the specified child to the parent at the given index using <ahref="#mxChildChange"class=LClassid=link238onMouseOver="ShowTip(event, 'tt36', 'link238')"onMouseOut="HideTip('tt36')">mxChildChange</a> and adds the change to the current transaction. If no index is specified then the child is appended to the parent’s array of children. Returns the inserted child.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>parent</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link239onMouseOver="ShowTip(event, 'tt22', 'link239')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the parent to contain the child.</td></tr><tr><tdclass=CDLEntry>child</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link240onMouseOver="ShowTip(event, 'tt22', 'link240')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the child to be inserted.</td></tr><tr><tdclass=CDLEntry>index</td><tdclass=CDLDescription>Optional integer that specifies the index of the child.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.cellAdded"></a>cellAdded</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.cellAdded = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update <ahref="#mxGraphModel.cells"class=LVariableid=link241onMouseOver="ShowTip(event, 'tt8', 'link241')"onMouseOut="HideTip('tt8')">cells</a> when a cell has been added. This implementation resolves collisions by creating new Ids. To change the ID of a cell after it was inserted into the model, use the following code:</p><p>(code delete model.cells[cell.getId()]; cell.setId(newId); model.cells[cell.getId()] = cell; (end)</p><p>If the change of the ID should be part of the command history, then the cell should be removed from the model and a clone with the new ID should be reinserted into the model instead.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link242onMouseOver="ShowTip(event, 'tt22', 'link242')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell that has been added.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.createId"></a>createId</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.createId = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Hook method to create an Id for the specified cell. This implementation concatenates <ahref="#mxGraphModel.prefix"class=LVariableid=link243onMouseOver="ShowTip(event, 'tt12', 'link243')"onMouseOut="HideTip('tt12')">prefix</a>, id and <ahref="#mxGraphModel.postfix"class=LVariableid=link244onMouseOver="ShowTip(event, 'tt13', 'link244')"onMouseOut="HideTip('tt13')">postfix</a> to create the Id and increments <ahref="#mxGraphModel.nextId"class=LVariableid=link245onMouseOver="ShowTip(event, 'tt14', 'link245')"onMouseOut="HideTip('tt14')">nextId</a>. The cell is ignored by this implementation, but can be used in overridden methods to prefix the Ids with eg. the cell type.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link246onMouseOver="ShowTip(event, 'tt22', 'link246')"onMouseOut="HideTip('tt22')">mxCell</a> to create the Id for.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.updateEdgeParents"></a>updateEdgeParents</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.updateEdgeParents = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>root</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Updates the parent for all edges that are connected to cell or one of its descendants using <ahref="#mxGraphModel.updateEdgeParent"class=LFunctionid=link247onMouseOver="ShowTip(event, 'tt40', 'link247')"onMouseOut="HideTip('tt40')">updateEdgeParent</a>.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.updateEdgeParent"></a>updateEdgeParent</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.updateEdgeParent = function(</td><tdclass="PParameter prettyprint "nowrap>edge,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>root</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the parent of the specified <ahref="mxCell-js.html#mxCell"class=LClassid=link248onMouseOver="ShowTip(event, 'tt22', 'link248')"onMouseOut="HideTip('tt22')">mxCell</a> to the nearest-common-ancestor of its two terminals.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>edge</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link249onMouseOver="ShowTip(event, 'tt22', 'link249')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the edge.</td></tr><tr><tdclass=CDLEntry>root</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link250onMouseOver="ShowTip(event, 'tt22', 'link250')"onMouseOut="HideTip('tt22')">mxCell</a> that represents the current root of the model.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getOrigin"></a>getOrigin</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getOrigin = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the absolute, accumulated origin for the children inside the given parent as an <ahref="../util/mxPoint-js.html#mxPoint"class=LClassid=link251onMouseOver="ShowTip(event, 'tt42', 'link251')"onMouseOut="HideTip('tt42')">mxPoint</a>.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getNearestCommonAncestor"></a>getNearestCommonAncestor</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getNearestCommonAncestor = function(</td><tdclass="PParameter prettyprint "nowrap>cell1,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>cell2</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the nearest common ancestor for the specified cells.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell1</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link252onMouseOver="ShowTip(event, 'tt22', 'link252')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the first cell in the tree.</td></tr><tr><tdclass=CDLEntry>cell2</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link253onMouseOver="ShowTip(event, 'tt22', 'link253')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the second cell in the tree.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.remove"></a>remove</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.remove = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Removes the specified cell from the model using <ahref="#mxChildChange"class=LClassid=link254onMouseOver="ShowTip(event, 'tt36', 'link254')"onMouseOut="HideTip('tt36')">mxChildChange</a> and adds the change to the current transaction. This operation will remove the cell and all of its children from the model. Returns the removed cell.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link255onMouseOver="ShowTip(event, 'tt22', 'link255')"onMouseOut="HideTip('tt22')">mxCell</a> that should be removed.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.cellRemoved"></a>cellRemoved</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.cellRemoved = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update <ahref="#mxGraphModel.cells"class=LVariableid=link256onMouseOver="ShowTip(event, 'tt8', 'link256')"onMouseOut="HideTip('tt8')">cells</a> when a cell has been removed.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link257onMouseOver="ShowTip(event, 'tt22', 'link257')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell that has been removed.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.parentForCellChanged"></a>parentForCellChanged</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.parentForCellChanged = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>parent,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>index</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the parent of a cell using <ahref="mxCell-js.html#mxCell.insert"class=LFunctionid=link258onMouseOver="ShowTip(event, 'tt47', 'link258')"onMouseOut="HideTip('tt47')">mxCell.insert</a> on the parent and return the previous parent.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link259onMouseOver="ShowTip(event, 'tt22', 'link259')"onMouseOut="HideTip('tt22')">mxCell</a> to update the parent for.</td></tr><tr><tdclass=CDLEntry>parent</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link260onMouseOver="ShowTip(event, 'tt22', 'link260')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new parent of the cell.</td></tr><tr><tdclass=CDLEntry>index</td><tdclass=CDLDescription>Optional integer that defines the index of the child in the parent’s child array.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getChildCount"></a>getChildCount</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getChildCount = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the number of children in the given cell.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link261onMouseOver="ShowTip(event, 'tt22', 'link261')"onMouseOut="HideTip('tt22')">mxCell</a> whose number of children should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getChildAt"></a>getChildAt</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getChildAt = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>index</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the child of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link262onMouseOver="ShowTip(event, 'tt22', 'link262')"onMouseOut="HideTip('tt22')">mxCell</a> at the given index.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link263onMouseOver="ShowTip(event, 'tt22', 'link263')"onMouseOut="HideTip('tt22')">mxCell</a> that represents the parent.</td></tr><tr><tdclass=CDLEntry>index</td><tdclass=CDLDescription>Integer that specifies the index of the child to be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getChildren"></a>getChildren</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getChildren = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns all children of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link264onMouseOver="ShowTip(event, 'tt22', 'link264')"onMouseOut="HideTip('tt22')">mxCell</a> as an array of <ahref="mxCell-js.html#mxCell"class=LClassid=link265onMouseOver="ShowTip(event, 'tt22', 'link265')"onMouseOut="HideTip('tt22')">mxCells</a>. The return value should be only be read.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link266onMouseOver="ShowTip(event, 'tt22', 'link266')"onMouseOut="HideTip('tt22')">mxCell</a> the represents the parent.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getChildVertices"></a>getChildVertices</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getChildVertices = function(</td><tdclass="PParameter prettyprint "nowrap>parent</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the child vertices of the given parent.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link267onMouseOver="ShowTip(event, 'tt22', 'link267')"onMouseOut="HideTip('tt22')">mxCell</a> whose child vertices should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getChildEdges"></a>getChildEdges</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getChildEdges = function(</td><tdclass="PParameter prettyprint "nowrap>parent</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the child edges of the given parent.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link268onMouseOver="ShowTip(event, 'tt22', 'link268')"onMouseOut="HideTip('tt22')">mxCell</a> whose child edges should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getChildCells"></a>getChildCells</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getChildCells = function(</td><tdclass="PParameter prettyprint "nowrap>parent,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>vertices,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>edges</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the children of the given cell that are vertices and/or edges depending on the arguments.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link269onMouseOver="ShowTip(event, 'tt22', 'link269')"onMouseOut="HideTip('tt22')">mxCell</a> the represents the parent.</td></tr><tr><tdclass=CDLEntry>vertices</td><tdclass=CDLDescription>Boolean indicating if child vertices should be returned. Default is false.</td></tr><tr><tdclass=CDLEntry>edges</td><tdclass=CDLDescription>Boolean indicating if child edges should be returned. Default is false.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getTerminal"></a>getTerminal</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getTerminal = function(</td><tdclass="PParameter prettyprint "nowrap>edge,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>isSource</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the source or target <ahref="mxCell-js.html#mxCell"class=LClassid=link270onMouseOver="ShowTip(event, 'tt22', 'link270')"onMouseOut="HideTip('tt22')">mxCell</a> of the given edge depending on the value of the boolean parameter.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>edge</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link271onMouseOver="ShowTip(event, 'tt22', 'link271')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the edge.</td></tr><tr><tdclass=CDLEntry>isSource</td><tdclass=CDLDescription>Boolean indicating which end of the edge should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.setTerminal"></a>setTerminal</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setTerminal = function(</td><tdclass="PParameter prettyprint "nowrap>edge,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>terminal,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>isSource</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the source or target terminal of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link272onMouseOver="ShowTip(event, 'tt22', 'link272')"onMouseOut="HideTip('tt22')">mxCell</a> using <ahref="#mxTerminalChange"class=LClassid=link273onMouseOver="ShowTip(event, 'tt56', 'link273')"onMouseOut="HideTip('tt56')">mxTerminalChange</a> and adds the change to the current transaction. This implementation updates the parent of the edge using <ahref="#mxGraphModel.updateEdgeParent"class=LFunctionid=link274onMouseOver="ShowTip(event, 'tt40', 'link274')"onMouseOut="HideTip('tt40')">updateEdgeParent</a> if required.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>edge</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link275onMouseOver="ShowTip(event, 'tt22', 'link275')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the edge.</td></tr><tr><tdclass=CDLEntry>terminal</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link276onMouseOver="ShowTip(event, 'tt22', 'link276')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new terminal.</td></tr><tr><tdclass=CDLEntry>isSource</td><tdclass=CDLDescription>Boolean indicating if the terminal is the new source or target terminal of the edge.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.setTerminals"></a>setTerminals</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setTerminals = function(</td><tdclass="PParameter prettyprint "nowrap>edge,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>source,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>target</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the source and target <ahref="mxCell-js.html#mxCell"class=LClassid=link277onMouseOver="ShowTip(event, 'tt22', 'link277')"onMouseOut="HideTip('tt22')">mxCell</a> of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link278onMouseOver="ShowTip(event, 'tt22', 'link278')"onMouseOut="HideTip('tt22')">mxCell</a> in a single transaction using <ahref="#mxGraphModel.setTerminal"class=LFunctionid=link279onMouseOver="ShowTip(event, 'tt55', 'link279')"onMouseOut="HideTip('tt55')">setTerminal</a> for each end of the edge.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>edge</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link280onMouseOver="ShowTip(event, 'tt22', 'link280')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the edge.</td></tr><tr><tdclass=CDLEntry>source</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link281onMouseOver="ShowTip(event, 'tt22', 'link281')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new source terminal.</td></tr><tr><tdclass=CDLEntry>target</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link282onMouseOver="ShowTip(event, 'tt22', 'link282')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new target terminal.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.terminalForCellChanged"></a>terminalForCellChanged</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.terminalForCellChanged = function(</td><tdclass="PParameter prettyprint "nowrap>edge,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>terminal,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>isSource</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner helper function to update the terminal of the edge using <ahref="mxCell-js.html#mxCell.insertEdge"class=LFunctionid=link283onMouseOver="ShowTip(event, 'tt59', 'link283')"onMouseOut="HideTip('tt59')">mxCell.insertEdge</a> and return the previous terminal.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>edge</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link284onMouseOver="ShowTip(event, 'tt22', 'link284')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the edge to be updated.</td></tr><tr><tdclass=CDLEntry>terminal</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link285onMouseOver="ShowTip(event, 'tt22', 'link285')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new terminal.</td></tr><tr><tdclass=CDLEntry>isSource</td><tdclass=CDLDescription>Boolean indicating if the terminal is the new source or target terminal of the edge.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getEdgeCount"></a>getEdgeCount</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getEdgeCount = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the number of distinct edges connected to the given cell.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link286onMouseOver="ShowTip(event, 'tt22', 'link286')"onMouseOut="HideTip('tt22')">mxCell</a> that represents the vertex.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getEdgeAt"></a>getEdgeAt</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getEdgeAt = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>index</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the edge of cell at the given index.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link287onMouseOver="ShowTip(event, 'tt22', 'link287')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the vertex.</td></tr><tr><tdclass=CDLEntry>index</td><tdclass=CDLDescription>Integer that specifies the index of the edge to return.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getDirectedEdgeCount"></a>getDirectedEdgeCount</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getDirectedEdgeCount = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>outgoing,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>ignoredEdge</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the number of incoming or outgoing edges, ignoring the given edge.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link288onMouseOver="ShowTip(event, 'tt22', 'link288')"onMouseOut="HideTip('tt22')">mxCell</a> whose edge count should be returned.</td></tr><tr><tdclass=CDLEntry>outgoing</td><tdclass=CDLDescription>Boolean that specifies if the number of outgoing or incoming edges should be returned.</td></tr><tr><tdclass=CDLEntry>ignoredEdge</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link289onMouseOver="ShowTip(event, 'tt22', 'link289')"onMouseOut="HideTip('tt22')">mxCell</a> that represents an edge to be ignored.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getConnections"></a>getConnections</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getConnections = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns all edges of the given cell without loops.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link290onMouseOver="ShowTip(event, 'tt22', 'link290')"onMouseOut="HideTip('tt22')">mxCell</a> whose edges should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getIncomingEdges"></a>getIncomingEdges</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getIncomingEdges = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the incoming edges of the given cell without loops.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link291onMouseOver="ShowTip(event, 'tt22', 'link291')"onMouseOut="HideTip('tt22')">mxCell</a> whose incoming edges should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getOutgoingEdges"></a>getOutgoingEdges</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getOutgoingEdges = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the outgoing edges of the given cell without loops.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link292onMouseOver="ShowTip(event, 'tt22', 'link292')"onMouseOut="HideTip('tt22')">mxCell</a> whose outgoing edges should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getEdges"></a>getEdges</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getEdges = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>incoming,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>outgoing,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>includeLoops</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns all distinct edges connected to this cell as a new array of <ahref="mxCell-js.html#mxCell"class=LClassid=link293onMouseOver="ShowTip(event, 'tt22', 'link293')"onMouseOut="HideTip('tt22')">mxCells</a>. If at least one of incoming or outgoing is true, then loops are ignored, otherwise if both are false, then all edges connected to the given cell are returned including loops.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link294onMouseOver="ShowTip(event, 'tt22', 'link294')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell.</td></tr><tr><tdclass=CDLEntry>incoming</td><tdclass=CDLDescription>Optional boolean that specifies if incoming edges should be returned. Default is true.</td></tr><tr><tdclass=CDLEntry>outgoing</td><tdclass=CDLDescription>Optional boolean that specifies if outgoing edges should be returned. Default is true.</td></tr><tr><tdclass=CDLEntry>includeLoops</td><tdclass=CDLDescription>Optional boolean that specifies if loops should be returned. Default is true.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getEdgesBetween"></a>getEdgesBetween</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getEdgesBetween = function(</td><tdclass="PParameter prettyprint "nowrap>source,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>target,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>directed</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns all edges between the given source and target pair. If directed is true, then only edges from the source to the target are returned, otherwise, all edges between the two cells are returned.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>source</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link295onMouseOver="ShowTip(event, 'tt22', 'link295')"onMouseOut="HideTip('tt22')">mxCell</a> that defines the source terminal of the edge to be returned.</td></tr><tr><tdclass=CDLEntry>target</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link296onMouseOver="ShowTip(event, 'tt22', 'link296')"onMouseOut="HideTip('tt22')">mxCell</a> that defines the target terminal of the edge to be returned.</td></tr><tr><tdclass=CDLEntry>directed</td><tdclass=CDLDescription>Optional boolean that specifies if the direction of the edge should be taken into account. Default is false.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getOpposites"></a>getOpposites</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getOpposites = function(</td><tdclass="PParameter prettyprint "nowrap>edges,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>terminal,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>sources,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>targets</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns all opposite vertices wrt terminal for the given edges, only returning sources and/or targets as specified. The result is returned as an array of <ahref="mxCell-js.html#mxCell"class=LClassid=link297onMouseOver="ShowTip(event, 'tt22', 'link297')"onMouseOut="HideTip('tt22')">mxCells</a>.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>edges</td><tdclass=CDLDescription>Array of <ahref="mxCell-js.html#mxCell"class=LClassid=link298onMouseOver="ShowTip(event, 'tt22', 'link298')"onMouseOut="HideTip('tt22')">mxCells</a> that contain the edges to be examined.</td></tr><tr><tdclass=CDLEntry>terminal</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link299onMouseOver="ShowTip(event, 'tt22', 'link299')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the known end of the edges.</td></tr><tr><tdclass=CDLEntry>sources</td><tdclass=CDLDescription>Boolean that specifies if source terminals should be contained in the result. Default is true.</td></tr><tr><tdclass=CDLEntry>targets</td><tdclass=CDLDescription>Boolean that specifies if target terminals should be contained in the result. Default is true.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getTopmostCells"></a>getTopmostCells</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getTopmostCells = function(</td><tdclass="PParameter prettyprint "nowrap>cells</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the topmost cells of the hierarchy in an array that contains no descendants for each <ahref="mxCell-js.html#mxCell"class=LClassid=link300onMouseOver="ShowTip(event, 'tt22', 'link300')"onMouseOut="HideTip('tt22')">mxCell</a> that it contains. Duplicates should be removed in the cells array to improve performance.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cells</td><tdclass=CDLDescription>Array of <ahref="mxCell-js.html#mxCell"class=LClassid=link301onMouseOver="ShowTip(event, 'tt22', 'link301')"onMouseOut="HideTip('tt22')">mxCells</a> whose topmost ancestors should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.isVertex"></a>isVertex</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isVertex = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the given cell is a vertex.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link302onMouseOver="ShowTip(event, 'tt22', 'link302')"onMouseOut="HideTip('tt22')">mxCell</a> that represents the possible vertex.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.isEdge"></a>isEdge</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isEdge = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the given cell is an edge.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link303onMouseOver="ShowTip(event, 'tt22', 'link303')"onMouseOut="HideTip('tt22')">mxCell</a> that represents the possible edge.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.isConnectable"></a>isConnectable</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isConnectable = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the given <ahref="mxCell-js.html#mxCell"class=LClassid=link304onMouseOver="ShowTip(event, 'tt22', 'link304')"onMouseOut="HideTip('tt22')">mxCell</a> is connectable. If <edgesConnectable> is false, then this function returns false for all edges else it returns the return value of <ahref="mxCell-js.html#mxCell.isConnectable"class=LFunctionid=link305onMouseOver="ShowTip(event, 'tt127', 'link305')"onMouseOut="HideTip('tt127')">mxCell.isConnectable</a>.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link306onMouseOver="ShowTip(event, 'tt22', 'link306')"onMouseOut="HideTip('tt22')">mxCell</a> whose connectable state should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getValue"></a>getValue</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getValue = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the user object of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link307onMouseOver="ShowTip(event, 'tt22', 'link307')"onMouseOut="HideTip('tt22')">mxCell</a> using <ahref="mxCell-js.html#mxCell.getValue"class=LFunctionid=link308onMouseOver="ShowTip(event, 'tt74', 'link308')"onMouseOut="HideTip('tt74')">mxCell.getValue</a>.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link309onMouseOver="ShowTip(event, 'tt22', 'link309')"onMouseOut="HideTip('tt22')">mxCell</a> whose user object should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.setValue"></a>setValue</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setValue = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>value</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the user object of then given <ahref="mxCell-js.html#mxCell"class=LClassid=link310onMouseOver="ShowTip(event, 'tt22', 'link310')"onMouseOut="HideTip('tt22')">mxCell</a> using <ahref="#mxValueChange"class=LClassid=link311onMouseOver="ShowTip(event, 'tt76', 'link311')"onMouseOut="HideTip('tt76')">mxValueChange</a> and adds the change to the current transaction.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link312onMouseOver="ShowTip(event, 'tt22', 'link312')"onMouseOut="HideTip('tt22')">mxCell</a> whose user object should be changed.</td></tr><tr><tdclass=CDLEntry>value</td><tdclass=CDLDescription>Object that defines the new user object.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.valueForCellChanged"></a>valueForCellChanged</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.valueForCellChanged = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>value</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the user object of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link313onMouseOver="ShowTip(event, 'tt22', 'link313')"onMouseOut="HideTip('tt22')">mxCell</a> using <ahref="mxCell-js.html#mxCell.valueChanged"class=LFunctionid=link314onMouseOver="ShowTip(event, 'tt78', 'link314')"onMouseOut="HideTip('tt78')">mxCell.valueChanged</a> and return the previous value, that is, the return value of <ahref="mxCell-js.html#mxCell.valueChanged"class=LFunctionid=link315onMouseOver="ShowTip(event, 'tt78', 'link315')"onMouseOut="HideTip('tt78')">mxCell.valueChanged</a>.</p><p>To change a specific attribute in an XML node, the following code can be used.</p><blockquote><preclass="prettyprint">graph.getModel().valueForCellChanged = function(cell, value)
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getGeometry"></a>getGeometry</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getGeometry = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the <ahref="mxGeometry-js.html#mxGeometry"class=LClassid=link316onMouseOver="ShowTip(event, 'tt80', 'link316')"onMouseOut="HideTip('tt80')">mxGeometry</a> of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link317onMouseOver="ShowTip(event, 'tt22', 'link317')"onMouseOut="HideTip('tt22')">mxCell</a>.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link318onMouseOver="ShowTip(event, 'tt22', 'link318')"onMouseOut="HideTip('tt22')">mxCell</a> whose geometry should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.setGeometry"></a>setGeometry</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setGeometry = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>geometry</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the <ahref="mxGeometry-js.html#mxGeometry"class=LClassid=link319onMouseOver="ShowTip(event, 'tt80', 'link319')"onMouseOut="HideTip('tt80')">mxGeometry</a> of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link320onMouseOver="ShowTip(event, 'tt22', 'link320')"onMouseOut="HideTip('tt22')">mxCell</a>. The actual update of the cell is carried out in <ahref="#mxGraphModel.geometryForCellChanged"class=LFunctionid=link321onMouseOver="ShowTip(event, 'tt82', 'link321')"onMouseOut="HideTip('tt82')">geometryForCellChanged</a>. The <ahref="#mxGeometryChange"class=LClassid=link322onMouseOver="ShowTip(event, 'tt128', 'link322')"onMouseOut="HideTip('tt128')">mxGeometryChange</a> action is used to encapsulate the change.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link323onMouseOver="ShowTip(event, 'tt22', 'link323')"onMouseOut="HideTip('tt22')">mxCell</a> whose geometry should be changed.</td></tr><tr><tdclass=CDLEntry>geometry</td><tdclass=CDLDescription><ahref="mxGeometry-js.html#mxGeometry"class=LClassid=link324onMouseOver="ShowTip(event, 'tt80', 'link324')"onMouseOut="HideTip('tt80')">mxGeometry</a> that defines the new geometry.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.geometryForCellChanged"></a>geometryForCellChanged</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.geometryForCellChanged = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>geometry</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the <ahref="mxGeometry-js.html#mxGeometry"class=LClassid=link325onMouseOver="ShowTip(event, 'tt80', 'link325')"onMouseOut="HideTip('tt80')">mxGeometry</a> of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link326onMouseOver="ShowTip(event, 'tt22', 'link326')"onMouseOut="HideTip('tt22')">mxCell</a> using <ahref="mxCell-js.html#mxCell.setGeometry"class=LFunctionid=link327onMouseOver="ShowTip(event, 'tt83', 'link327')"onMouseOut="HideTip('tt83')">mxCell.setGeometry</a> and return the previous <ahref="mxGeometry-js.html#mxGeometry"class=LClassid=link328onMouseOver="ShowTip(event, 'tt80', 'link328')"onMouseOut="HideTip('tt80')">mxGeometry</a>.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getStyle"></a>getStyle</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getStyle = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the style of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link329onMouseOver="ShowTip(event, 'tt22', 'link329')"onMouseOut="HideTip('tt22')">mxCell</a>.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link330onMouseOver="ShowTip(event, 'tt22', 'link330')"onMouseOut="HideTip('tt22')">mxCell</a> whose style should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.setStyle"></a>setStyle</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setStyle = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>style</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the style of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link331onMouseOver="ShowTip(event, 'tt22', 'link331')"onMouseOut="HideTip('tt22')">mxCell</a> using <ahref="#mxStyleChange"class=LClassid=link332onMouseOver="ShowTip(event, 'tt86', 'link332')"onMouseOut="HideTip('tt86')">mxStyleChange</a> and adds the change to the current transaction.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link333onMouseOver="ShowTip(event, 'tt22', 'link333')"onMouseOut="HideTip('tt22')">mxCell</a> whose style should be changed.</td></tr><tr><tdclass=CDLEntry>style</td><tdclass=CDLDescription>String of the form [stylename;|key=value;] to specify the new cell style.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.styleForCellChanged"></a>styleForCellChanged</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.styleForCellChanged = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>style</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the style of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link334onMouseOver="ShowTip(event, 'tt22', 'link334')"onMouseOut="HideTip('tt22')">mxCell</a> using <ahref="mxCell-js.html#mxCell.setStyle"class=LFunctionid=link335onMouseOver="ShowTip(event, 'tt88', 'link335')"onMouseOut="HideTip('tt88')">mxCell.setStyle</a> and return the previous style.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link336onMouseOver="ShowTip(event, 'tt22', 'link336')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell to be updated.</td></tr><tr><tdclass=CDLEntry>style</td><tdclass=CDLDescription>String of the form [stylename;|key=value;] to specify the new cell style.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.isCollapsed"></a>isCollapsed</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isCollapsed = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the given <ahref="mxCell-js.html#mxCell"class=LClassid=link337onMouseOver="ShowTip(event, 'tt22', 'link337')"onMouseOut="HideTip('tt22')">mxCell</a> is collapsed.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link338onMouseOver="ShowTip(event, 'tt22', 'link338')"onMouseOut="HideTip('tt22')">mxCell</a> whose collapsed state should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.setCollapsed"></a>setCollapsed</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setCollapsed = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>collapsed</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the collapsed state of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link339onMouseOver="ShowTip(event, 'tt22', 'link339')"onMouseOut="HideTip('tt22')">mxCell</a> using <ahref="#mxCollapseChange"class=LClassid=link340onMouseOver="ShowTip(event, 'tt91', 'link340')"onMouseOut="HideTip('tt91')">mxCollapseChange</a> and adds the change to the current transaction.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link341onMouseOver="ShowTip(event, 'tt22', 'link341')"onMouseOut="HideTip('tt22')">mxCell</a> whose collapsed state should be changed.</td></tr><tr><tdclass=CDLEntry>collapsed</td><tdclass=CDLDescription>Boolean that specifies the new collpased state.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.collapsedStateForCellChanged"></a>collapsedStateForCellChanged</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.collapsedStateForCellChanged = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>collapsed</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the collapsed state of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link342onMouseOver="ShowTip(event, 'tt22', 'link342')"onMouseOut="HideTip('tt22')">mxCell</a> using <ahref="mxCell-js.html#mxCell.setCollapsed"class=LFunctionid=link343onMouseOver="ShowTip(event, 'tt93', 'link343')"onMouseOut="HideTip('tt93')">mxCell.setCollapsed</a> and return the previous collapsed state.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link344onMouseOver="ShowTip(event, 'tt22', 'link344')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell to be updated.</td></tr><tr><tdclass=CDLEntry>collapsed</td><tdclass=CDLDescription>Boolean that specifies the new collpased state.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.isVisible"></a>isVisible</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isVisible = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the given <ahref="mxCell-js.html#mxCell"class=LClassid=link345onMouseOver="ShowTip(event, 'tt22', 'link345')"onMouseOut="HideTip('tt22')">mxCell</a> is visible.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link346onMouseOver="ShowTip(event, 'tt22', 'link346')"onMouseOut="HideTip('tt22')">mxCell</a> whose visible state should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.setVisible"></a>setVisible</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setVisible = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>visible</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the visible state of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link347onMouseOver="ShowTip(event, 'tt22', 'link347')"onMouseOut="HideTip('tt22')">mxCell</a> using <ahref="#mxVisibleChange"class=LClassid=link348onMouseOver="ShowTip(event, 'tt96', 'link348')"onMouseOut="HideTip('tt96')">mxVisibleChange</a> and adds the change to the current transaction.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link349onMouseOver="ShowTip(event, 'tt22', 'link349')"onMouseOut="HideTip('tt22')">mxCell</a> whose visible state should be changed.</td></tr><tr><tdclass=CDLEntry>visible</td><tdclass=CDLDescription>Boolean that specifies the new visible state.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.visibleStateForCellChanged"></a>visibleStateForCellChanged</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.visibleStateForCellChanged = function(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>visible</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the visible state of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link350onMouseOver="ShowTip(event, 'tt22', 'link350')"onMouseOut="HideTip('tt22')">mxCell</a> using <ahref="mxCell-js.html#mxCell.setCollapsed"class=LFunctionid=link351onMouseOver="ShowTip(event, 'tt93', 'link351')"onMouseOut="HideTip('tt93')">mxCell.setCollapsed</a> and return the previous visible state.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link352onMouseOver="ShowTip(event, 'tt22', 'link352')"onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell to be updated.</td></tr><tr><tdclass=CDLEntry>visible</td><tdclass=CDLDescription>Boolean that specifies the new visible state.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.execute"></a>execute</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.execute = function(</td><tdclass="PParameter prettyprint "nowrap>change</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Executes the given edit and fires events if required. The edit object requires an execute function which is invoked. The edit is added to the <ahref="#mxGraphModel.currentEdit"class=LVariableid=link353onMouseOver="ShowTip(event, 'tt15', 'link353')"onMouseOut="HideTip('tt15')">currentEdit</a> between <ahref="#mxGraphModel.beginUpdate"class=LFunctionid=link354onMouseOver="ShowTip(event, 'tt4', 'link354')"onMouseOut="HideTip('tt4')">beginUpdate</a> and <ahref="#mxGraphModel.endUpdate"class=LFunctionid=link355onMouseOver="ShowTip(event, 'tt5', 'link355')"onMouseOut="HideTip('tt5')">endUpdate</a> calls, so that events will be fired if this execute is an individual transaction, that is, if no previous <ahref="#mxGraphModel.beginUpdate"class=LFunctionid=link356onMouseOver="ShowTip(event, 'tt4', 'link356')"onMouseOut="HideTip('tt4')">beginUpdate</a> calls have been made without calling <ahref="#mxGraphModel.endUpdate"class=LFunctionid=link357onMouseOver="ShowTip(event, 'tt5', 'link357')"onMouseOut="HideTip('tt5')">endUpdate</a>. This implementation fires an <ahref="#mxGraphModel.execute"class=LFunctionid=link358onMouseOver="ShowTip(event, 'tt98', 'link358')"onMouseOut="HideTip('tt98')">execute</a> event before executing the given change.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>change</td><tdclass=CDLDescription>Object that described the change.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.beginUpdate"></a>beginUpdate</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.beginUpdate = function()</td></tr></table></blockquote><p>Increments the <ahref="#mxGraphModel.updateLevel"class=LVariableid=link359onMouseOver="ShowTip(event, 'tt3', 'link359')"onMouseOut="HideTip('tt3')">updateLevel</a> by one. The event notification is queued until <ahref="#mxGraphModel.updateLevel"class=LVariableid=link360onMouseOver="ShowTip(event, 'tt3', 'link360')"onMouseOut="HideTip('tt3')">updateLevel</a> reaches 0 by use of <ahref="#mxGraphModel.endUpdate"class=LFunctionid=link361onMouseOver="ShowTip(event, 'tt5', 'link361')"onMouseOut="HideTip('tt5')">endUpdate</a>.</p><p>All changes on <ahref="#mxGraphModel.mxGraphModel"class=LFunctionid=link362onMouseOver="ShowTip(event, 'tt6', 'link362')"onMouseOut="HideTip('tt6')">mxGraphModel</a> are transactional, that is, they are executed in a single undoable change on the model (without transaction isolation). Therefore, if you want to combine any number of changes into a single undoable change, you should group any two or more API calls that modify the graph model between <ahref="#mxGraphModel.beginUpdate"class=LFunctionid=link363onMouseOver="ShowTip(event, 'tt4', 'link363')"onMouseOut="HideTip('tt4')">beginUpdate</a> and <ahref="#mxGraphModel.endUpdate"class=LFunctionid=link364onMouseOver="ShowTip(event, 'tt5', 'link364')"onMouseOut="HideTip('tt5')">endUpdate</a> calls as shown here:</p><blockquote><preclass="prettyprint">var model = graph.getModel();
}</pre></blockquote><p>Of course there is a shortcut for appending a sequence of cells into the default parent:</p><blockquote><preclass="prettyprint">graph.addCells([v1, v2]).</pre></blockquote></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.endUpdate"></a>endUpdate</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.endUpdate = function()</td></tr></table></blockquote><p>Decrements the <ahref="#mxGraphModel.updateLevel"class=LVariableid=link365onMouseOver="ShowTip(event, 'tt3', 'link365')"onMouseOut="HideTip('tt3')">updateLevel</a> by one and fires an <undo> event if the <ahref="#mxGraphModel.updateLevel"class=LVariableid=link366onMouseOver="ShowTip(event, 'tt3', 'link366')"onMouseOut="HideTip('tt3')">updateLevel</a> reaches 0. This function indirectly fires a <change> event by invoking the notify function on the <ahref="#mxGraphModel.currentEdit"class=LVariableid=link367onMouseOver="ShowTip(event, 'tt15', 'link367')"onMouseOut="HideTip('tt15')">currentEdit</a> und then creates a new <ahref="#mxGraphModel.currentEdit"class=LVariableid=link368onMouseOver="ShowTip(event, 'tt15', 'link368')"onMouseOut="HideTip('tt15')">currentEdit</a> using <ahref="#mxGraphModel.createUndoableEdit"class=LFunctionid=link369onMouseOver="ShowTip(event, 'tt99', 'link369')"onMouseOut="HideTip('tt99')">createUndoableEdit</a>.</p><p>The <undo> event is fired only once per edit, whereas the <change> event is fired whenever the notify function is invoked, that is, on undo and redo of the edit.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.createUndoableEdit"></a>createUndoableEdit</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.createUndoableEdit = function()</td></tr></table></blockquote><p>Creates a new <ahref="../util/mxUndoableEdit-js.html#mxUndoableEdit"class=LClassid=link370onMouseOver="ShowTip(event, 'tt100', 'link370')"onMouseOut="HideTip('tt100')">mxUndoableEdit</a> that implements the notify function to fire a <change> and <notify> event through the <ahref="../util/mxUndoableEdit-js.html#mxUndoableEdit"class=LClassid=link371onMouseOver="ShowTip(event, 'tt100', 'link371')"onMouseOut="HideTip('tt100')">mxUndoableEdit</a>’s source.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.mergeChildren"></a>mergeChildren</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.mergeChildren = function(</td><tdclass="PParameter prettyprint "nowrap>from,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>to,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>cloneAllEdges</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Merges the children of the given cell into the given target cell inside this model. All cells are cloned unless there is a corresponding cell in the model with the same id, in which case the source cell is ignored and all edges are connected to the corresponding cell in this model. Edges are considered to have no identity and are always cloned unless the cloneAllEdges flag is set to false, in which case edges with the same id in the target model are reconnected to reflect the terminals of the source edges.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.mergeChildren"></a>mergeChildren</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.mergeChildrenImpl = function(</td><tdclass="PParameter prettyprint "nowrap>from,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>to,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>cloneAllEdges,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>mapping</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Clones the children of the source cell into the given target cell in this model and adds an entry to the mapping that maps from the source cell to the target cell with the same id or the clone of the source cell that was inserted into this model.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.getParents"></a>getParents</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getParents = function(</td><tdclass="PParameter prettyprint "nowrap>cells</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns an array that represents the set (no duplicates) of all parents for the given array of cells.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cells</td><tdclass=CDLDescription>Array of cells whose parents should be returned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.cloneCell"></a>cloneCell</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.cloneCell = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns a deep clone of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link372onMouseOver="ShowTip(event, 'tt22', 'link372')"onMouseOut="HideTip('tt22')">mxCell</a> (including the children) which is created using <ahref="#mxGraphModel.cloneCells"class=LFunctionid=link373onMouseOver="ShowTip(event, 'tt104', 'link373')"onMouseOut="HideTip('tt104')">cloneCells</a>.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cell</td><tdclass=CDLDescription><ahref="mxCell-js.html#mxCell"class=LClassid=link374onMouseOver="ShowTip(event, 'tt22', 'link374')"onMouseOut="HideTip('tt22')">mxCell</a> to be cloned.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.cloneCells"></a>cloneCells</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.cloneCells = function(</td><tdclass="PParameter prettyprint "nowrap>cells,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>includeChildren,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>mapping</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns an array of clones for the given array of <ahref="mxCell-js.html#mxCell"class=LClassid=link375onMouseOver="ShowTip(event, 'tt22', 'link375')"onMouseOut="HideTip('tt22')">mxCells</a>. Depending on the value of includeChildren, a deep clone is created for each cell. Connections are restored based if the corresponding cell is contained in the passed in array.</p><h4class=CHeading>Parameters</h4><tableborder=0cellspacing=0cellpadding=0class=CDescriptionList><tr><tdclass=CDLEntry>cells</td><tdclass=CDLDescription>Array of <ahref="mxCell-js.html#mxCell"class=LClassid=link376onMouseOver="ShowTip(event, 'tt22', 'link376')"onMouseOut="HideTip('tt22')">mxCell</a> to be cloned.</td></tr><tr><tdclass=CDLEntry>includeChildren</td><tdclass=CDLDescription>Boolean indicating if the cells should be cloned with all descendants.</td></tr><tr><tdclass=CDLEntry>mapping</td><tdclass=CDLDescription>Optional mapping for existing clones.</td></tr></table></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.cellCloned"></a>cellCloned</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.cellCloned = function(</td><tdclass="PParameter prettyprint "nowrap>cell</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Hook for cloning the cell. This returns cell.clone() or any possible exceptions.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGraphModel.restoreClone"></a>restoreClone</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.restoreClone = function(</td><tdclass="PParameter prettyprint "nowrap>clone,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>mapping</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner helper method for restoring the connections in a network of cloned cells.</p></div></div></div>
<divclass="CClass"><divclass=CTopic><h2class=CTitle><aname="mxRootChange"></a>mxRootChange</h2><divclass=CBody><p>Action to change the root in a model.</p><!--START_ND_SUMMARY--><divclass=Summary><divclass=STitle>Summary</div><divclass=SBorder><tableborder=0cellspacing=0cellpadding=0class=STable><trclass="SGroup"><tdclass=SEntry><ahref="#mxRootChange.Functions">Functions</a></td><tdclass=SDescription></td></tr><trclass="SFunction SIndent1 SMarked"><tdclass=SEntry><ahref="#mxRootChange.mxRootChange"id=link377onMouseOver="ShowTip(event, 'tt108', 'link377')"onMouseOut="HideTip('tt108')">mxRootChange</a></td><tdclass=SDescription>Constructs a change of the root in the specified model.</td></tr><trclass="SFunction SIndent1"><tdclass=SEntry><ahref="#mxRootChange.execute"id=link378onMouseOver="ShowTip(event, 'tt109', 'link378')"onMouseOut="HideTip('tt109')">execute</a></td><tdclass=SDescription>Carries out a change of the root using <ahref="#mxGraphModel.rootChanged"class=LFunctionid=link379onMouseOver="ShowTip(event, 'tt29', 'link379')"onMouseOut="HideTip('tt29')">mxGraphModel.rootChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxRootChange.mxRootChange"></a>mxRootChange</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>function mxRootChange(</td><tdclass="PParameter prettyprint "nowrap>model,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>root</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Constructs a change of the root in the specified model.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxRootChange.execute"></a>execute</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxRootChange.prototype.execute = function()</td></tr></table></blockquote><p>Carries out a change of the root using <ahref="#mxGraphModel.rootChanged"class=LFunctionid=link380onMouseOver="ShowTip(event, 'tt29', 'link380')"onMouseOut="HideTip('tt29')">mxGraphModel.rootChanged</a>.</p></div></div></div>
<divclass="CClass"><divclass=CTopic><h2class=CTitle><aname="mxChildChange"></a>mxChildChange</h2><divclass=CBody><p>Action to add or remove a child in a model.</p><!--START_ND_SUMMARY--><divclass=Summary><divclass=STitle>Summary</div><divclass=SBorder><tableborder=0cellspacing=0cellpadding=0class=STable><trclass="SGroup"><tdclass=SEntry><ahref="#mxChildChange.Functions">Functions</a></td><tdclass=SDescription></td></tr><trclass="SFunction SIndent1 SMarked"><tdclass=SEntry><ahref="#mxChildChange.mxChildChange"id=link381onMouseOver="ShowTip(event, 'tt110', 'link381')"onMouseOut="HideTip('tt110')">mxChildChange</a></td><tdclass=SDescription>Constructs a change of a child in the specified model.</td></tr><trclass="SFunction SIndent1"><tdclass=SEntry><ahref="#mxChildChange.execute"id=link382onMouseOver="ShowTip(event, 'tt111', 'link382')"onMouseOut="HideTip('tt111')">execute</a></td><tdclass=SDescription>Changes the parent of <child> using <ahref="#mxGraphModel.parentForCellChanged"class=LFunctionid=link383onMouseOver="ShowTip(event, 'tt46', 'link383')"onMouseOut="HideTip('tt46')">mxGraphModel.parentForCellChanged</a> and removes or restores the cell’s connections.</td></tr><trclass="SFunction SIndent1 SMarked"><tdclass=SEntry><ahref="#mxChildChange.disconnect">disconnect</a></td><tdclass=SDescription>Disconnects the given cell recursively from its terminals and stores the previous terminal in the cell’s terminals.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxChildChange.mxChildChange"></a>mxChildChange</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>function mxChildChange(</td><tdclass="PParameter prettyprint "nowrap>model,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>parent,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>child,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>index</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Constructs a change of a child in the specified model.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxChildChange.execute"></a>execute</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxChildChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the parent of <child> using <ahref="#mxGraphModel.parentForCellChanged"class=LFunctionid=link384onMouseOver="ShowTip(event, 'tt46', 'link384')"onMouseOut="HideTip('tt46')">mxGraphModel.parentForCellChanged</a> and removes or restores the cell’s connections.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxChildChange.disconnect"></a>disconnect</h3><divclass=CBody><p>Disconnects the given cell recursively from its terminals and stores the previous terminal in the cell’s terminals.</p></div></div></div>
<divclass="CClass"><divclass=CTopic><h2class=CTitle><aname="mxTerminalChange"></a>mxTerminalChange</h2><divclass=CBody><p>Action to change a terminal in a model.</p><!--START_ND_SUMMARY--><divclass=Summary><divclass=STitle>Summary</div><divclass=SBorder><tableborder=0cellspacing=0cellpadding=0class=STable><trclass="SGroup"><tdclass=SEntry><ahref="#mxTerminalChange.Functions">Functions</a></td><tdclass=SDescription></td></tr><trclass="SFunction SIndent1 SMarked"><tdclass=SEntry><ahref="#mxTerminalChange.mxTerminalChange"id=link385onMouseOver="ShowTip(event, 'tt112', 'link385')"onMouseOut="HideTip('tt112')">mxTerminalChange</a></td><tdclass=SDescription>Constructs a change of a terminal in the specified model.</td></tr><trclass="SFunction SIndent1"><tdclass=SEntry><ahref="#mxTerminalChange.execute"id=link386onMouseOver="ShowTip(event, 'tt113', 'link386')"onMouseOut="HideTip('tt113')">execute</a></td><tdclass=SDescription>Changes the terminal of <cell> to <previous> using <ahref="#mxGraphModel.terminalForCellChanged"class=LFunctionid=link387onMouseOver="ShowTip(event, 'tt58', 'link387')"onMouseOut="HideTip('tt58')">mxGraphModel.terminalForCellChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxTerminalChange.mxTerminalChange"></a>mxTerminalChange</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>function mxTerminalChange(</td><tdclass="PParameter prettyprint "nowrap>model,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>terminal,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>source</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Constructs a change of a terminal in the specified model.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxTerminalChange.execute"></a>execute</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxTerminalChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the terminal of <cell> to <previous> using <ahref="#mxGraphModel.terminalForCellChanged"class=LFunctionid=link388onMouseOver="ShowTip(event, 'tt58', 'link388')"onMouseOut="HideTip('tt58')">mxGraphModel.terminalForCellChanged</a>.</p></div></div></div>
<divclass="CClass"><divclass=CTopic><h2class=CTitle><aname="mxValueChange"></a>mxValueChange</h2><divclass=CBody><p>Action to change a user object in a model.</p><!--START_ND_SUMMARY--><divclass=Summary><divclass=STitle>Summary</div><divclass=SBorder><tableborder=0cellspacing=0cellpadding=0class=STable><trclass="SGroup"><tdclass=SEntry><ahref="#mxValueChange.Functions">Functions</a></td><tdclass=SDescription></td></tr><trclass="SFunction SIndent1 SMarked"><tdclass=SEntry><ahref="#mxValueChange.mxValueChange"id=link389onMouseOver="ShowTip(event, 'tt114', 'link389')"onMouseOut="HideTip('tt114')">mxValueChange</a></td><tdclass=SDescription>Constructs a change of a user object in the specified model.</td></tr><trclass="SFunction SIndent1"><tdclass=SEntry><ahref="#mxValueChange.execute"id=link390onMouseOver="ShowTip(event, 'tt115', 'link390')"onMouseOut="HideTip('tt115')">execute</a></td><tdclass=SDescription>Changes the value of <cell> to <previous> using <ahref="#mxGraphModel.valueForCellChanged"class=LFunctionid=link391onMouseOver="ShowTip(event, 'tt77', 'link391')"onMouseOut="HideTip('tt77')">mxGraphModel.valueForCellChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxValueChange.mxValueChange"></a>mxValueChange</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>function mxValueChange(</td><tdclass="PParameter prettyprint "nowrap>model,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>value</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Constructs a change of a user object in the specified model.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxValueChange.execute"></a>execute</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxValueChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the value of <cell> to <previous> using <ahref="#mxGraphModel.valueForCellChanged"class=LFunctionid=link392onMouseOver="ShowTip(event, 'tt77', 'link392')"onMouseOut="HideTip('tt77')">mxGraphModel.valueForCellChanged</a>.</p></div></div></div>
<divclass="CClass"><divclass=CTopic><h2class=CTitle><aname="mxStyleChange"></a>mxStyleChange</h2><divclass=CBody><p>Action to change a cell’s style in a model.</p><!--START_ND_SUMMARY--><divclass=Summary><divclass=STitle>Summary</div><divclass=SBorder><tableborder=0cellspacing=0cellpadding=0class=STable><trclass="SGroup"><tdclass=SEntry><ahref="#mxStyleChange.Functions">Functions</a></td><tdclass=SDescription></td></tr><trclass="SFunction SIndent1 SMarked"><tdclass=SEntry><ahref="#mxStyleChange.mxStyleChange"id=link393onMouseOver="ShowTip(event, 'tt116', 'link393')"onMouseOut="HideTip('tt116')">mxStyleChange</a></td><tdclass=SDescription>Constructs a change of a style in the specified model.</td></tr><trclass="SFunction SIndent1"><tdclass=SEntry><ahref="#mxStyleChange.execute"id=link394onMouseOver="ShowTip(event, 'tt117', 'link394')"onMouseOut="HideTip('tt117')">execute</a></td><tdclass=SDescription>Changes the style of <cell> to <previous> using <ahref="#mxGraphModel.styleForCellChanged"class=LFunctionid=link395onMouseOver="ShowTip(event, 'tt87', 'link395')"onMouseOut="HideTip('tt87')">mxGraphModel.styleForCellChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxStyleChange.mxStyleChange"></a>mxStyleChange</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>function mxStyleChange(</td><tdclass="PParameter prettyprint "nowrap>model,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>style</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Constructs a change of a style in the specified model.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxStyleChange.execute"></a>execute</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxStyleChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the style of <cell> to <previous> using <ahref="#mxGraphModel.styleForCellChanged"class=LFunctionid=link396onMouseOver="ShowTip(event, 'tt87', 'link396')"onMouseOut="HideTip('tt87')">mxGraphModel.styleForCellChanged</a>.</p></div></div></div>
<divclass="CClass"><divclass=CTopic><h2class=CTitle><aname="mxGeometryChange"></a>mxGeometryChange</h2><divclass=CBody><p>Action to change a cell’s geometry in a model.</p><!--START_ND_SUMMARY--><divclass=Summary><divclass=STitle>Summary</div><divclass=SBorder><tableborder=0cellspacing=0cellpadding=0class=STable><trclass="SGroup"><tdclass=SEntry><ahref="#mxGeometryChange.Functions">Functions</a></td><tdclass=SDescription></td></tr><trclass="SFunction SIndent1 SMarked"><tdclass=SEntry><ahref="#mxGeometryChange.mxGeometryChange"id=link397onMouseOver="ShowTip(event, 'tt118', 'link397')"onMouseOut="HideTip('tt118')">mxGeometryChange</a></td><tdclass=SDescription>Constructs a change of a geometry in the specified model.</td></tr><trclass="SFunction SIndent1"><tdclass=SEntry><ahref="#mxGeometryChange.execute"id=link398onMouseOver="ShowTip(event, 'tt119', 'link398')"onMouseOut="HideTip('tt119')">execute</a></td><tdclass=SDescription>Changes the geometry of <cell> ro <previous> using <ahref="#mxGraphModel.geometryForCellChanged"class=LFunctionid=link399onMouseOver="ShowTip(event, 'tt82', 'link399')"onMouseOut="HideTip('tt82')">mxGraphModel.geometryForCellChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGeometryChange.mxGeometryChange"></a>mxGeometryChange</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>function mxGeometryChange(</td><tdclass="PParameter prettyprint "nowrap>model,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>geometry</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Constructs a change of a geometry in the specified model.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxGeometryChange.execute"></a>execute</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGeometryChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the geometry of <cell> ro <previous> using <ahref="#mxGraphModel.geometryForCellChanged"class=LFunctionid=link400onMouseOver="ShowTip(event, 'tt82', 'link400')"onMouseOut="HideTip('tt82')">mxGraphModel.geometryForCellChanged</a>.</p></div></div></div>
<divclass="CClass"><divclass=CTopic><h2class=CTitle><aname="mxCollapseChange"></a>mxCollapseChange</h2><divclass=CBody><p>Action to change a cell’s collapsed state in a model.</p><!--START_ND_SUMMARY--><divclass=Summary><divclass=STitle>Summary</div><divclass=SBorder><tableborder=0cellspacing=0cellpadding=0class=STable><trclass="SGroup"><tdclass=SEntry><ahref="#mxCollapseChange.Functions">Functions</a></td><tdclass=SDescription></td></tr><trclass="SFunction SIndent1 SMarked"><tdclass=SEntry><ahref="#mxCollapseChange.mxCollapseChange"id=link401onMouseOver="ShowTip(event, 'tt120', 'link401')"onMouseOut="HideTip('tt120')">mxCollapseChange</a></td><tdclass=SDescription>Constructs a change of a collapsed state in the specified model.</td></tr><trclass="SFunction SIndent1"><tdclass=SEntry><ahref="#mxCollapseChange.execute"id=link402onMouseOver="ShowTip(event, 'tt121', 'link402')"onMouseOut="HideTip('tt121')">execute</a></td><tdclass=SDescription>Changes the collapsed state of <cell> to <previous> using <ahref="#mxGraphModel.collapsedStateForCellChanged"class=LFunctionid=link403onMouseOver="ShowTip(event, 'tt92', 'link403')"onMouseOut="HideTip('tt92')">mxGraphModel.collapsedStateForCellChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxCollapseChange.mxCollapseChange"></a>mxCollapseChange</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>function mxCollapseChange(</td><tdclass="PParameter prettyprint "nowrap>model,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>collapsed</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Constructs a change of a collapsed state in the specified model.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxCollapseChange.execute"></a>execute</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxCollapseChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the collapsed state of <cell> to <previous> using <ahref="#mxGraphModel.collapsedStateForCellChanged"class=LFunctionid=link404onMouseOver="ShowTip(event, 'tt92', 'link404')"onMouseOut="HideTip('tt92')">mxGraphModel.collapsedStateForCellChanged</a>.</p></div></div></div>
<divclass="CClass"><divclass=CTopic><h2class=CTitle><aname="mxVisibleChange"></a>mxVisibleChange</h2><divclass=CBody><p>Action to change a cell’s visible state in a model.</p><!--START_ND_SUMMARY--><divclass=Summary><divclass=STitle>Summary</div><divclass=SBorder><tableborder=0cellspacing=0cellpadding=0class=STable><trclass="SGroup"><tdclass=SEntry><ahref="#mxVisibleChange.Functions">Functions</a></td><tdclass=SDescription></td></tr><trclass="SFunction SIndent1 SMarked"><tdclass=SEntry><ahref="#mxVisibleChange.mxVisibleChange"id=link405onMouseOver="ShowTip(event, 'tt122', 'link405')"onMouseOut="HideTip('tt122')">mxVisibleChange</a></td><tdclass=SDescription>Constructs a change of a visible state in the specified model.</td></tr><trclass="SFunction SIndent1"><tdclass=SEntry><ahref="#mxVisibleChange.execute"id=link406onMouseOver="ShowTip(event, 'tt123', 'link406')"onMouseOut="HideTip('tt123')">execute</a></td><tdclass=SDescription>Changes the visible state of <cell> to <previous> using <ahref="#mxGraphModel.visibleStateForCellChanged"class=LFunctionid=link407onMouseOver="ShowTip(event, 'tt97', 'link407')"onMouseOut="HideTip('tt97')">mxGraphModel.visibleStateForCellChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxVisibleChange.mxVisibleChange"></a>mxVisibleChange</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>function mxVisibleChange(</td><tdclass="PParameter prettyprint "nowrap>model,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>visible</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Constructs a change of a visible state in the specified model.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxVisibleChange.execute"></a>execute</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxVisibleChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the visible state of <cell> to <previous> using <ahref="#mxGraphModel.visibleStateForCellChanged"class=LFunctionid=link408onMouseOver="ShowTip(event, 'tt97', 'link408')"onMouseOut="HideTip('tt97')">mxGraphModel.visibleStateForCellChanged</a>.</p></div></div></div>
<divclass="CClass"><divclass=CTopic><h2class=CTitle><aname="mxCellAttributeChange"></a>mxCellAttributeChange</h2><divclass=CBody><p>Action to change the attribute of a cell’s user object. There is no method on the graph model that uses this action. To use the action, you can use the code shown in the example below.</p><h4class=CHeading>Example</h4><p>To change the attributeName in the cell’s user object to attributeValue, use the following code:</p><blockquote><preclass="prettyprint">model.beginUpdate();
}</pre></blockquote><!--START_ND_SUMMARY--><divclass=Summary><divclass=STitle>Summary</div><divclass=SBorder><tableborder=0cellspacing=0cellpadding=0class=STable><trclass="SGroup"><tdclass=SEntry><ahref="#mxCellAttributeChange.Functions">Functions</a></td><tdclass=SDescription></td></tr><trclass="SFunction SIndent1 SMarked"><tdclass=SEntry><ahref="#mxCellAttributeChange.mxCellAttributeChange"id=link409onMouseOver="ShowTip(event, 'tt124', 'link409')"onMouseOut="HideTip('tt124')">mxCellAttributeChange</a></td><tdclass=SDescription>Constructs a change of a attribute of the DOM node stored as the value of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link410onMouseOver="ShowTip(event, 'tt22', 'link410')"onMouseOut="HideTip('tt22')">mxCell</a>.</td></tr><trclass="SFunction SIndent1"><tdclass=SEntry><ahref="#mxCellAttributeChange.execute"id=link411onMouseOver="ShowTip(event, 'tt125', 'link411')"onMouseOut="HideTip('tt125')">execute</a></td><tdclass=SDescription>Changes the attribute of the cell’s user object by using <ahref="mxCell-js.html#mxCell.setAttribute"class=LFunctionid=link412onMouseOver="ShowTip(event, 'tt126', 'link412')"onMouseOut="HideTip('tt126')">mxCell.setAttribute</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxCellAttributeChange.mxCellAttributeChange"></a>mxCellAttributeChange</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>function mxCellAttributeChange(</td><tdclass="PParameter prettyprint "nowrap>cell,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>attribute,</td></tr><tr><td></td><tdclass="PParameter prettyprint "nowrap>value</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Constructs a change of a attribute of the DOM node stored as the value of the given <ahref="mxCell-js.html#mxCell"class=LClassid=link413onMouseOver="ShowTip(event, 'tt22', 'link413')"onMouseOut="HideTip('tt22')">mxCell</a>.</p></div></div></div>
<divclass="CFunction"><divclass=CTopic><h3class=CTitle><aname="mxCellAttributeChange.execute"></a>execute</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxCellAttributeChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the attribute of the cell’s user object by using <ahref="mxCell-js.html#mxCell.setAttribute"class=LFunctionid=link414onMouseOver="ShowTip(event, 'tt126', 'link414')"onMouseOut="HideTip('tt126')">mxCell.setAttribute</a>.</p></div></div></div>
<divclass=CToolTipid="tt1"><divclass=CClass>Base class for objects that dispatch named events. </div></div><divclass=CToolTipid="tt2"><divclass=CEvent>Fires when an undoable edit is dispatched. </div></div><divclass=CToolTipid="tt3"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.updateLevel</td></tr></table></blockquote>Counter for the depth of nested transactions. </div></div><divclass=CToolTipid="tt4"><divclass=CFunction><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.beginUpdate = function()</td></tr></table></blockquote>Increments the updateLevel by one. </div></div><divclass=CToolTipid="tt5"><divclass=CFunction><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.endUpdate = function()</td></tr></table></blockquote>Decrements the updateLevel by one and fires an undo event if the updateLevel reaches 0. </div></div><divclass=CToolTipid="tt6"><divclass=CFunction><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><td><tableborder=0cellspacing=0cellpadding=0><tr><tdclass="PBeforeParameters prettyprint "nowrap>function mxGraphModel(</td><tdclass="PParameter prettyprint "nowrap>root</td><tdclass="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Constructs a new graph model. </div></div><divclass=CToolTipid="tt7"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.root</td></tr></table></blockquote>Holds the root cell, which in turn contains the cells that represent the layers of the diagram as child cells. </div></div><divclass=CToolTipid="tt8"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.cells</td></tr></table></blockquote>Maps from Ids to cells.</div></div><divclass=CToolTipid="tt9"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.maintainEdgeParent</td></tr></table></blockquote>Specifies if edges should automatically be moved into the nearest common ancestor of their terminals. </div></div><divclass=CToolTipid="tt10"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.ignoreRelativeEdgeParent</td></tr></table></blockquote>Specifies if relative edge parents should be ignored for finding the nearest common ancestors of an edge’s terminals. </div></div><divclass=CToolTipid="tt11"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.createIds</td></tr></table></blockquote>Specifies if the model should automatically create Ids for new cells. </div></div><divclass=CToolTipid="tt12"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.prefix</td></tr></table></blockquote>Defines the prefix of new Ids. </div></div><divclass=CToolTipid="tt13"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.postfix</td></tr></table></blockquote>Defines the postfix of new Ids. </div></div><divclass=CToolTipid="tt14"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.nextId</td></tr></table></blockquote>Specifies the next Id to be created. </div></div><divclass=CToolTipid="tt15"><divclass=CVariable><blockquote><tableborder=0cellspacing=0cellpadding=0class="Prototype"><tr><tdclass="prettyprint">mxGraphModel.prototype.currentEdit</td></