maxGraph/docs/js-api/files/model/mxGraphModel-js.html

399 lines
264 KiB
HTML
Raw Normal View History

2012-05-21 20:32:26 +00:00
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
2017-06-27 11:43:19 +00:00
<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>mxGraphModel</title><link rel="stylesheet" type="text/css" href="../../styles/main.css"><script language=JavaScript src="../../javascript/main.js"></script><script language=JavaScript src="../../javascript/prettify.js"></script><script language=JavaScript src="../../javascript/searchdata.js"></script></head><body class="ContentPage" onLoad="NDOnLoad();prettyPrint();"><script language=JavaScript><!--
2012-05-21 20:32:26 +00:00
if (browserType) {document.write("<div class=" + browserType + ">");if (browserVer) {document.write("<div class=" + browserVer + ">"); }}// --></script>
2017-06-27 11:43:19 +00:00
<!-- Generated by Natural Docs, version 1.51 -->
2012-05-21 20:32:26 +00:00
<!-- http://www.naturaldocs.org -->
<!-- saved from url=(0026)http://www.naturaldocs.org -->
2016-04-13 07:03:38 +00:00
<div id=Content><div class="CClass"><div class=CTopic id=MainTopic><h1 class=CTitle><a name="mxGraphModel"></a>mxGraphModel</h1><div class=CBody><p>Extends <a href="../util/mxEventSource-js.html#mxEventSource" class=LClass id=link196 onMouseOver="ShowTip(event, 'tt1', 'link196')" onMouseOut="HideTip('tt1')">mxEventSource</a> to implement a graph model.&nbsp; The graph model acts as a wrapper around the cells which are in charge of storing the actual graph datastructure.&nbsp; 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><h4 class=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.&nbsp; This means each cell is contained in a layer.&nbsp; 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.&nbsp; To identify a layer, the <a href="#mxGraphModel.isLayer" class=LFunction id=link197 onMouseOver="ShowTip(event, 'tt31', 'link197')" onMouseOut="HideTip('tt31')">isLayer</a> function is used.&nbsp; It returns true if the parent of the given cell is the root of the model.</p><h4 class=CHeading>Events</h4><p>See events section for more details.&nbsp; There is a new set of events for tracking transactional changes as they happen.&nbsp; The events are called startEdit for the initial beginUpdate, executed for each executed change and endEdit for the terminal endUpdate.&nbsp; The executed event contains a property called change which represents the change after execution.</p><h4 class=CHeading>Encoding the model</h4><h4 class=CHeading>To encode a graph model, use the following code</h4><blockquote><pre class="prettyprint">var enc = new mxCodec();
2012-05-21 20:32:26 +00:00
var node = enc.encode(graph.getModel());</pre></blockquote><p>This will create an XML node that contains all the model information.</p><h4 class=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><pre class="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 &lt; 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><pre class="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><pre class="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><pre class="prettyprint">var edit = new mxUndoableEdit(model, false);
edit.changes = changes;
edit.notify = function()
{
edit.source.fireEvent(new mxEventObject(mxEvent.CHANGE,
'edit', edit, 'changes', edit.changes));
edit.source.fireEvent(new mxEventObject(mxEvent.NOTIFY,
'edit', edit, 'changes', edit.changes));
}
model.fireEvent(new mxEventObject(mxEvent.UNDO, 'edit', edit));
model.fireEvent(new mxEventObject(mxEvent.CHANGE,
2017-01-16 08:36:34 +00:00
'edit', edit, 'changes', changes));</pre></blockquote><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SMain"><td class=SEntry><a href="#mxGraphModel" >mxGraphModel</a></td><td class=SDescription>Extends <a href="../util/mxEventSource-js.html#mxEventSource" class=LClass id=link1 onMouseOver="ShowTip(event, 'tt1', 'link1')" onMouseOut="HideTip('tt1')">mxEventSource</a> to implement a graph model. </td></tr><tr class="SGroup SIndent1"><td class=SEntry><a href="#mxGraphModel.Events" >Events</a></td><td class=SDescription></td></tr><tr class="SEvent SIndent2 SMarked"><td class=SEntry><a href="#mxGraphModel.mxEvent.CHANGE" >mxEvent.<wbr>CHANGE</a></td><td class=SDescription>Fires when an undoable edit is dispatched. </td></tr><tr class="SEvent SIndent2"><td class=SEntry><a href="#mxGraphModel.mxEvent.NOTIFY" >mxEvent.<wbr>NOTIFY</a></td><td class=SDescription>Same as <a href="#mxGraphModel.mxEvent.CHANGE" class=LEvent id=link2 onMouseOver="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><tr class="SEvent SIndent2 SMarked"><td class=SEntry><a href="#mxGraphModel.mxEvent.EXECUTE" >mxEvent.<wbr>EXECUTE</a></td><td class=SDescription>Fires between begin- and endUpdate and after an atomic change was executed in the model. </td></tr><tr class="SEvent SIndent2"><td class=SEntry><a href="#mxGraphModel.mxEvent.EXECUTED" >mxEvent.<wbr>EXECUTED</a></td><td class=SDescription>Fires between START_EDIT and END_EDIT after an atomic change was executed. </td></tr><tr class="SEvent SIndent2 SMarked"><td class=SEntry><a href="#mxGraphModel.mxEvent.BEGIN_UPDATE" >mxEvent.<wbr>BEGIN_UPDATE</a></td><td class=SDescription>Fires after the <a href="#mxGraphModel.updateLevel" class=LVariable id=link3 onMouseOver="ShowTip(event, 'tt3', 'link3')" onMouseOut="HideTip('tt3')">updateLevel</a> was incremented in <a href="#mxGraphModel.beginUpdate" class=LFunction id=link4 onMouseOver="ShowTip(event, 'tt4', 'link4')" onMouseOut="HideTip('tt4')">beginUpdate</a>. </td></tr><tr class="SEvent SIndent2"><td class=SEntry><a href="#mxGraphModel.mxEvent.START_EDIT" >mxEvent.<wbr>START_EDIT</a></td><td class=SDescription>Fires after the <a href="#mxGraphModel.updateLevel" class=LVariable id=link5 onMouseOver="ShowTip(event, 'tt3', 'link5')" onMouseOut="HideTip('tt3')">updateLevel</a> was changed from 0 to 1. </td></tr><tr class="SEvent SIndent2 SMarked"><td class=SEntry><a href="#mxGraphModel.mxEvent.END_UPDATE" >mxEvent.<wbr>END_UPDATE</a></td><td class=SDescription>Fires after the <a href="#mxGraphModel.updateLevel" class=LVariable id=link6 onMouseOver="ShowTip(event, 'tt3', 'link6')" onMouseOut="HideTip('tt3')">updateLevel</a> was decreased in <a href="#mxGraphModel.endUpdate" class=LFunction id=link7 onMouseOver="ShowTip(event, 'tt5', 'link7')" onMouseOut="HideTip('tt5')">endUpdate</a> but before any notification or change dispatching. </td></tr><tr class="SEvent SIndent2"><td class=SEntry><a href="#mxGraphModel.mxEvent.END_EDIT" >mxEvent.<wbr>END_EDIT</a></td><td class=SDescription>Fires after the <a href="#mxGraphModel.updateLevel" class=LVariable id=link8 onMouseOver="ShowTip(event, 'tt3', 'link8')" onMouseOut="HideTip('tt3')">updateLevel</a> was changed from 1 to 0. </td></tr><tr class="SEvent SIndent2 SMarked"><td class=SEntry><a href="#mxGraphModel.mxEvent.BEFORE_UNDO" >mxEvent.<wbr>BEFORE_UNDO</a></td><td class=SDescription>Fires before the change is dispatched after the update level has reached 0 in <a href="#mxGraphModel.endUpdate" class=LFunction id=link9 onMouseOver="ShowTip(event, 'tt5', 'link9')" onMouseOut="HideTip('tt5')">endUpdate</a>. </td></tr><tr class="SEvent SIndent2"><td class=SEntry><a href="#mxGraphModel.mxEvent.UNDO" >mxEvent.UNDO</a></td><td class=SDescription>Fires after the change was dispatched in <a href="#mxGraphModel.endUpdate" class=LFunction id=link10 onM
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.Events"></a>Events</h3></div></div>
2016-04-13 07:03:38 +00:00
<div class="CEvent"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.mxEvent.CHANGE"></a>mxEvent.<wbr>CHANGE</h3><div class=CBody><p>Fires when an undoable edit is dispatched.&nbsp; The &lt;code&gt;edit&lt;/code&gt; property contains the <a href="../util/mxUndoableEdit-js.html#mxUndoableEdit" class=LClass id=link198 onMouseOver="ShowTip(event, 'tt100', 'link198')" onMouseOut="HideTip('tt100')">mxUndoableEdit</a>.&nbsp; The &lt;code&gt;changes&lt;/code&gt; property contains the array of atomic changes inside the undoable edit.&nbsp; The changes property is &lt;strong&gt;deprecated&lt;/strong&gt;, please use edit.changes instead.</p><h4 class=CHeading>Example</h4><h4 class=CHeading>For finding newly inserted cells, the following code can be used</h4><blockquote><pre class="prettyprint">graph.model.addListener(mxEvent.CHANGE, function(sender, evt)
2012-05-21 20:32:26 +00:00
{
var changes = evt.getProperty('edit').changes;
for (var i = 0; i &lt; changes.length; i++)
{
var change = changes[i];
if (change instanceof mxChildChange &amp;&amp;
change.change.previous == null)
{
graph.startEditingAtCell(change.child);
break;
}
}
});</pre></blockquote></div></div></div>
2016-04-13 07:03:38 +00:00
<div class="CEvent"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.mxEvent.NOTIFY"></a>mxEvent.<wbr>NOTIFY</h3><div class=CBody><p>Same as <a href="#mxGraphModel.mxEvent.CHANGE" class=LEvent id=link199 onMouseOver="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.&nbsp; In such a setup, only local changes should trigger a notify event and all changes should trigger a change event.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CEvent"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.mxEvent.EXECUTE"></a>mxEvent.<wbr>EXECUTE</h3><div class=CBody><p>Fires between begin- and endUpdate and after an atomic change was executed in the model.&nbsp; The &lt;code&gt;change&lt;/code&gt; property contains the atomic change that was executed.</p></div></div></div>
2013-04-04 11:51:15 +00:00
<div class="CEvent"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.mxEvent.EXECUTED"></a>mxEvent.<wbr>EXECUTED</h3><div class=CBody><p>Fires between START_EDIT and END_EDIT after an atomic change was executed.&nbsp; The &lt;code&gt;change&lt;/code&gt; property contains the change that was executed.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2016-04-13 07:03:38 +00:00
<div class="CEvent"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.mxEvent.BEGIN_UPDATE"></a>mxEvent.<wbr>BEGIN_UPDATE</h3><div class=CBody><p>Fires after the <a href="#mxGraphModel.updateLevel" class=LVariable id=link200 onMouseOver="ShowTip(event, 'tt3', 'link200')" onMouseOut="HideTip('tt3')">updateLevel</a> was incremented in <a href="#mxGraphModel.beginUpdate" class=LFunction id=link201 onMouseOver="ShowTip(event, 'tt4', 'link201')" onMouseOut="HideTip('tt4')">beginUpdate</a>.&nbsp; This event contains no properties.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2016-04-13 07:03:38 +00:00
<div class="CEvent"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.mxEvent.START_EDIT"></a>mxEvent.<wbr>START_EDIT</h3><div class=CBody><p>Fires after the <a href="#mxGraphModel.updateLevel" class=LVariable id=link202 onMouseOver="ShowTip(event, 'tt3', 'link202')" onMouseOut="HideTip('tt3')">updateLevel</a> was changed from 0 to 1.&nbsp; This event contains no properties.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2016-04-13 07:03:38 +00:00
<div class="CEvent"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.mxEvent.END_UPDATE"></a>mxEvent.<wbr>END_UPDATE</h3><div class=CBody><p>Fires after the <a href="#mxGraphModel.updateLevel" class=LVariable id=link203 onMouseOver="ShowTip(event, 'tt3', 'link203')" onMouseOut="HideTip('tt3')">updateLevel</a> was decreased in <a href="#mxGraphModel.endUpdate" class=LFunction id=link204 onMouseOver="ShowTip(event, 'tt5', 'link204')" onMouseOut="HideTip('tt5')">endUpdate</a> but before any notification or change dispatching.&nbsp; The &lt;code&gt;edit&lt;/code&gt; property contains the <a href="#mxGraphModel.currentEdit" class=LVariable id=link205 onMouseOver="ShowTip(event, 'tt15', 'link205')" onMouseOut="HideTip('tt15')">currentEdit</a>.</p></div></div></div>
2013-04-04 11:51:15 +00:00
2016-04-13 07:03:38 +00:00
<div class="CEvent"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.mxEvent.END_EDIT"></a>mxEvent.<wbr>END_EDIT</h3><div class=CBody><p>Fires after the <a href="#mxGraphModel.updateLevel" class=LVariable id=link206 onMouseOver="ShowTip(event, 'tt3', 'link206')" onMouseOut="HideTip('tt3')">updateLevel</a> was changed from 1 to 0.&nbsp; This event contains no properties.</p></div></div></div>
2013-04-04 11:51:15 +00:00
2016-04-13 07:03:38 +00:00
<div class="CEvent"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.mxEvent.BEFORE_UNDO"></a>mxEvent.<wbr>BEFORE_UNDO</h3><div class=CBody><p>Fires before the change is dispatched after the update level has reached 0 in <a href="#mxGraphModel.endUpdate" class=LFunction id=link207 onMouseOver="ShowTip(event, 'tt5', 'link207')" onMouseOut="HideTip('tt5')">endUpdate</a>.&nbsp; The &lt;code&gt;edit&lt;/code&gt; property contains the &lt;curreneEdit&gt;.</p></div></div></div>
2013-04-04 11:51:15 +00:00
2016-04-13 07:03:38 +00:00
<div class="CEvent"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.mxEvent.UNDO"></a>mxEvent.UNDO</h3><div class=CBody><p>Fires after the change was dispatched in <a href="#mxGraphModel.endUpdate" class=LFunction id=link208 onMouseOver="ShowTip(event, 'tt5', 'link208')" onMouseOut="HideTip('tt5')">endUpdate</a>.&nbsp; The &lt;code&gt;edit&lt;/code&gt; property contains the <a href="#mxGraphModel.currentEdit" class=LVariable id=link209 onMouseOver="ShowTip(event, 'tt15', 'link209')" onMouseOut="HideTip('tt15')">currentEdit</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.Functions"></a>Functions</h3></div></div>
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.mxGraphModel"></a>mxGraphModel</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>function mxGraphModel(</td><td class="PParameter prettyprint " nowrap>root</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Constructs a new graph model.&nbsp; If no root is specified then a new root <a href="mxCell-js.html#mxCell" class=LClass id=link210 onMouseOver="ShowTip(event, 'tt22', 'link210')" onMouseOut="HideTip('tt22')">mxCell</a> with a default layer is created.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>root</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link211 onMouseOver="ShowTip(event, 'tt22', 'link211')" onMouseOut="HideTip('tt22')">mxCell</a> that represents the root cell.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.Variables"></a>Variables</h3></div></div>
2017-06-27 11:43:19 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.root"></a>root</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="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.&nbsp; That is, the actual elements of the diagram are supposed to live in the third generation of cells and below.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.cells"></a>cells</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.cells</td></tr></table></blockquote><p>Maps from Ids to cells.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.maintainEdgeParent"></a>maintainEdgeParent</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.maintainEdgeParent</td></tr></table></blockquote><p>Specifies if edges should automatically be moved into the nearest common ancestor of their terminals.&nbsp; Default is true.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.ignoreRelativeEdgeParent"></a>ignoreRelativeEdgeParent</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="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&rsquo;s terminals.&nbsp; Default is true.</p></div></div></div>
2016-04-13 07:03:38 +00:00
2017-06-27 11:43:19 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.createIds"></a>createIds</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.createIds</td></tr></table></blockquote><p>Specifies if the model should automatically create Ids for new cells.&nbsp; Default is true.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.prefix"></a>prefix</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.prefix</td></tr></table></blockquote><p>Defines the prefix of new Ids.&nbsp; Default is an empty string.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.postfix"></a>postfix</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.postfix</td></tr></table></blockquote><p>Defines the postfix of new Ids.&nbsp; Default is an empty string.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.nextId"></a>nextId</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.nextId</td></tr></table></blockquote><p>Specifies the next Id to be created.&nbsp; Initial value is 0.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.currentEdit"></a>currentEdit</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.currentEdit</td></tr></table></blockquote><p>Holds the changes for the current transaction.&nbsp; If the transaction is closed then a new object is created for this variable using <a href="#mxGraphModel.createUndoableEdit" class=LFunction id=link212 onMouseOver="ShowTip(event, 'tt99', 'link212')" onMouseOut="HideTip('tt99')">createUndoableEdit</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.updateLevel"></a>updateLevel</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.updateLevel</td></tr></table></blockquote><p>Counter for the depth of nested transactions.&nbsp; Each call to <a href="#mxGraphModel.beginUpdate" class=LFunction id=link213 onMouseOver="ShowTip(event, 'tt4', 'link213')" onMouseOut="HideTip('tt4')">beginUpdate</a> will increment this number and each call to <a href="#mxGraphModel.endUpdate" class=LFunction id=link214 onMouseOver="ShowTip(event, 'tt5', 'link214')" onMouseOut="HideTip('tt5')">endUpdate</a> will decrement it.&nbsp; When the counter reaches 0, the transaction is closed and the respective events are fired.&nbsp; Initial value is 0.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CVariable"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.endingUpdate"></a>endingUpdate</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.endingUpdate</td></tr></table></blockquote><p>True if the program flow is currently inside endUpdate.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.Functions"></a>Functions</h3></div></div>
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.clear"></a>clear</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.clear = function()</td></tr></table></blockquote><p>Sets a new root using <a href="#mxGraphModel.createRoot" class=LFunction id=link215 onMouseOver="ShowTip(event, 'tt18', 'link215')" onMouseOut="HideTip('tt18')">createRoot</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.isCreateIds"></a>isCreateIds</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.isCreateIds = function()</td></tr></table></blockquote><p>Returns <a href="#mxGraphModel.createIds" class=LVariable id=link216 onMouseOver="ShowTip(event, 'tt11', 'link216')" onMouseOut="HideTip('tt11')">createIds</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.setCreateIds"></a>setCreateIds</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setCreateIds = function(</td><td class="PParameter prettyprint " nowrap>value</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets <a href="#mxGraphModel.createIds" class=LVariable id=link217 onMouseOver="ShowTip(event, 'tt11', 'link217')" onMouseOut="HideTip('tt11')">createIds</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.createRoot"></a>createRoot</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="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>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getCell"></a>getCell</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getCell = function(</td><td class="PParameter prettyprint " nowrap>id</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the <a href="mxCell-js.html#mxCell" class=LClass id=link218 onMouseOver="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><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>id</td><td class=CDLDescription>A string representing the Id of the cell.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.filterCells"></a>filterCells</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.filterCells = function(</td><td class="PParameter prettyprint " nowrap>cells,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>filter</td><td class="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>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getDescendants"></a>getDescendants</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getDescendants = function(</td><td class="PParameter prettyprint " nowrap>parent</td><td class="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><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>parent</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link219 onMouseOver="ShowTip(event, 'tt22', 'link219')" onMouseOut="HideTip('tt22')">mxCell</a> whose descendants should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.filterDescendants"></a>filterDescendants</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.filterDescendants = function(</td><td class="PParameter prettyprint " nowrap>filter,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>parent</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Visits all cells recursively and applies the specified filter function to each cell.&nbsp; If the function returns true then the cell is added to the resulting array.&nbsp; The parent and result paramters are optional.&nbsp; If parent is not specified then the recursion starts at <a href="#mxGraphModel.root" class=LVariable id=link220 onMouseOver="ShowTip(event, 'tt7', 'link220')" onMouseOut="HideTip('tt7')">root</a>.</p><h4 class=CHeading>Example</h4><p>The following example extracts all vertices from a given model:</p><blockquote><pre class="prettyprint">var filter = function(cell)
2012-05-21 20:32:26 +00:00
{
return model.isVertex(cell);
}
2016-04-13 07:03:38 +00:00
var vertices = model.filterDescendants(filter);</pre></blockquote><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>filter</td><td class=CDLDescription>JavaScript function that takes an <a href="mxCell-js.html#mxCell" class=LClass id=link221 onMouseOver="ShowTip(event, 'tt22', 'link221')" onMouseOut="HideTip('tt22')">mxCell</a> as an argument and returns a boolean.</td></tr><tr><td class=CDLEntry>parent</td><td class=CDLDescription>Optional <a href="mxCell-js.html#mxCell" class=LClass id=link222 onMouseOver="ShowTip(event, 'tt22', 'link222')" onMouseOut="HideTip('tt22')">mxCell</a> that is used as the root of the recursion.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getRoot"></a>getRoot</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getRoot = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="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><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription>Optional <a href="mxCell-js.html#mxCell" class=LClass id=link223 onMouseOver="ShowTip(event, 'tt22', 'link223')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the child.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.setRoot"></a>setRoot</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setRoot = function(</td><td class="PParameter prettyprint " nowrap>root</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the <a href="#mxGraphModel.root" class=LVariable id=link224 onMouseOver="ShowTip(event, 'tt7', 'link224')" onMouseOut="HideTip('tt7')">root</a> of the model using <a href="#mxRootChange" class=LClass id=link225 onMouseOver="ShowTip(event, 'tt28', 'link225')" onMouseOut="HideTip('tt28')">mxRootChange</a> and adds the change to the current transaction.&nbsp; This resets all datastructures in the model and is the preferred way of clearing an existing model.&nbsp; Returns the new root.</p><h4 class=CHeading>Example</h4><blockquote><pre class="prettyprint">var root = new mxCell();
2012-05-21 20:32:26 +00:00
root.insert(new mxCell());
2016-04-13 07:03:38 +00:00
model.setRoot(root);</pre></blockquote><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>root</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link226 onMouseOver="ShowTip(event, 'tt22', 'link226')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new root.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.rootChanged"></a>rootChanged</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.rootChanged = function(</td><td class="PParameter prettyprint " nowrap>root</td><td class="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 <a href="#mxGraphModel.cells" class=LVariable id=link227 onMouseOver="ShowTip(event, 'tt8', 'link227')" onMouseOut="HideTip('tt8')">cells</a> and <a href="#mxGraphModel.nextId" class=LVariable id=link228 onMouseOver="ShowTip(event, 'tt14', 'link228')" onMouseOut="HideTip('tt14')">nextId</a>.&nbsp; Returns the previous root.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>root</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link229 onMouseOver="ShowTip(event, 'tt22', 'link229')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new root.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.isRoot"></a>isRoot</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isRoot = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="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><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link230 onMouseOver="ShowTip(event, 'tt22', 'link230')" onMouseOut="HideTip('tt22')">mxCell</a> that represents the possible root.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.isLayer"></a>isLayer</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isLayer = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if <a href="#mxGraphModel.isRoot" class=LFunction id=link231 onMouseOver="ShowTip(event, 'tt30', 'link231')" onMouseOut="HideTip('tt30')">isRoot</a> returns true for the parent of the given cell.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link232 onMouseOver="ShowTip(event, 'tt22', 'link232')" onMouseOut="HideTip('tt22')">mxCell</a> that represents the possible layer.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.isAncestor"></a>isAncestor</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isAncestor = function(</td><td class="PParameter prettyprint " nowrap>parent,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>child</td><td class="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><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>parent</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link233 onMouseOver="ShowTip(event, 'tt22', 'link233')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the parent.</td></tr><tr><td class=CDLEntry>child</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link234 onMouseOver="ShowTip(event, 'tt22', 'link234')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the child.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.contains"></a>contains</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.contains = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the model contains the given <a href="mxCell-js.html#mxCell" class=LClass id=link235 onMouseOver="ShowTip(event, 'tt22', 'link235')" onMouseOut="HideTip('tt22')">mxCell</a>.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link236 onMouseOver="ShowTip(event, 'tt22', 'link236')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getParent"></a>getParent</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getParent = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the parent of the given cell.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link237 onMouseOver="ShowTip(event, 'tt22', 'link237')" onMouseOut="HideTip('tt22')">mxCell</a> whose parent should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.add"></a>add</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.add = function(</td><td class="PParameter prettyprint " nowrap>parent,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>child,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>index</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Adds the specified child to the parent at the given index using <a href="#mxChildChange" class=LClass id=link238 onMouseOver="ShowTip(event, 'tt36', 'link238')" onMouseOut="HideTip('tt36')">mxChildChange</a> and adds the change to the current transaction.&nbsp; If no index is specified then the child is appended to the parent&rsquo;s array of children.&nbsp; Returns the inserted child.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>parent</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link239 onMouseOver="ShowTip(event, 'tt22', 'link239')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the parent to contain the child.</td></tr><tr><td class=CDLEntry>child</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link240 onMouseOver="ShowTip(event, 'tt22', 'link240')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the child to be inserted.</td></tr><tr><td class=CDLEntry>index</td><td class=CDLDescription>Optional integer that specifies the index of the child.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.cellAdded"></a>cellAdded</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.cellAdded = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update <a href="#mxGraphModel.cells" class=LVariable id=link241 onMouseOver="ShowTip(event, 'tt8', 'link241')" onMouseOut="HideTip('tt8')">cells</a> when a cell has been added.&nbsp; This implementation resolves collisions by creating new Ids.&nbsp; 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><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link242 onMouseOver="ShowTip(event, 'tt22', 'link242')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell that has been added.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.createId"></a>createId</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.createId = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Hook method to create an Id for the specified cell.&nbsp; This implementation concatenates <a href="#mxGraphModel.prefix" class=LVariable id=link243 onMouseOver="ShowTip(event, 'tt12', 'link243')" onMouseOut="HideTip('tt12')">prefix</a>, id and <a href="#mxGraphModel.postfix" class=LVariable id=link244 onMouseOver="ShowTip(event, 'tt13', 'link244')" onMouseOut="HideTip('tt13')">postfix</a> to create the Id and increments <a href="#mxGraphModel.nextId" class=LVariable id=link245 onMouseOver="ShowTip(event, 'tt14', 'link245')" onMouseOut="HideTip('tt14')">nextId</a>.&nbsp; The cell is ignored by this implementation, but can be used in overridden methods to prefix the Ids with eg. the cell type.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link246 onMouseOver="ShowTip(event, 'tt22', 'link246')" onMouseOut="HideTip('tt22')">mxCell</a> to create the Id for.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.updateEdgeParents"></a>updateEdgeParents</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.updateEdgeParents = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>root</td><td class="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 <a href="#mxGraphModel.updateEdgeParent" class=LFunction id=link247 onMouseOver="ShowTip(event, 'tt40', 'link247')" onMouseOut="HideTip('tt40')">updateEdgeParent</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.updateEdgeParent"></a>updateEdgeParent</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.updateEdgeParent = function(</td><td class="PParameter prettyprint " nowrap>edge,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>root</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the parent of the specified <a href="mxCell-js.html#mxCell" class=LClass id=link248 onMouseOver="ShowTip(event, 'tt22', 'link248')" onMouseOut="HideTip('tt22')">mxCell</a> to the nearest-common-ancestor of its two terminals.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>edge</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link249 onMouseOver="ShowTip(event, 'tt22', 'link249')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the edge.</td></tr><tr><td class=CDLEntry>root</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link250 onMouseOver="ShowTip(event, 'tt22', 'link250')" onMouseOut="HideTip('tt22')">mxCell</a> that represents the current root of the model.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getOrigin"></a>getOrigin</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getOrigin = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="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 <a href="../util/mxPoint-js.html#mxPoint" class=LClass id=link251 onMouseOver="ShowTip(event, 'tt42', 'link251')" onMouseOut="HideTip('tt42')">mxPoint</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getNearestCommonAncestor"></a>getNearestCommonAncestor</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getNearestCommonAncestor = function(</td><td class="PParameter prettyprint " nowrap>cell1,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>cell2</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the nearest common ancestor for the specified cells.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell1</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link252 onMouseOver="ShowTip(event, 'tt22', 'link252')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the first cell in the tree.</td></tr><tr><td class=CDLEntry>cell2</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link253 onMouseOver="ShowTip(event, 'tt22', 'link253')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the second cell in the tree.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.remove"></a>remove</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.remove = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Removes the specified cell from the model using <a href="#mxChildChange" class=LClass id=link254 onMouseOver="ShowTip(event, 'tt36', 'link254')" onMouseOut="HideTip('tt36')">mxChildChange</a> and adds the change to the current transaction.&nbsp; This operation will remove the cell and all of its children from the model.&nbsp; Returns the removed cell.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link255 onMouseOver="ShowTip(event, 'tt22', 'link255')" onMouseOut="HideTip('tt22')">mxCell</a> that should be removed.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.cellRemoved"></a>cellRemoved</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.cellRemoved = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update <a href="#mxGraphModel.cells" class=LVariable id=link256 onMouseOver="ShowTip(event, 'tt8', 'link256')" onMouseOut="HideTip('tt8')">cells</a> when a cell has been removed.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link257 onMouseOver="ShowTip(event, 'tt22', 'link257')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell that has been removed.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.parentForCellChanged"></a>parentForCellChanged</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.parentForCellChanged = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>parent,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>index</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the parent of a cell using <a href="mxCell-js.html#mxCell.insert" class=LFunction id=link258 onMouseOver="ShowTip(event, 'tt47', 'link258')" onMouseOut="HideTip('tt47')">mxCell.insert</a> on the parent and return the previous parent.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link259 onMouseOver="ShowTip(event, 'tt22', 'link259')" onMouseOut="HideTip('tt22')">mxCell</a> to update the parent for.</td></tr><tr><td class=CDLEntry>parent</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link260 onMouseOver="ShowTip(event, 'tt22', 'link260')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new parent of the cell.</td></tr><tr><td class=CDLEntry>index</td><td class=CDLDescription>Optional integer that defines the index of the child in the parent&rsquo;s child array.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getChildCount"></a>getChildCount</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getChildCount = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the number of children in the given cell.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link261 onMouseOver="ShowTip(event, 'tt22', 'link261')" onMouseOut="HideTip('tt22')">mxCell</a> whose number of children should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getChildAt"></a>getChildAt</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getChildAt = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>index</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the child of the given <a href="mxCell-js.html#mxCell" class=LClass id=link262 onMouseOver="ShowTip(event, 'tt22', 'link262')" onMouseOut="HideTip('tt22')">mxCell</a> at the given index.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link263 onMouseOver="ShowTip(event, 'tt22', 'link263')" onMouseOut="HideTip('tt22')">mxCell</a> that represents the parent.</td></tr><tr><td class=CDLEntry>index</td><td class=CDLDescription>Integer that specifies the index of the child to be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getChildren"></a>getChildren</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getChildren = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns all children of the given <a href="mxCell-js.html#mxCell" class=LClass id=link264 onMouseOver="ShowTip(event, 'tt22', 'link264')" onMouseOut="HideTip('tt22')">mxCell</a> as an array of <a href="mxCell-js.html#mxCell" class=LClass id=link265 onMouseOver="ShowTip(event, 'tt22', 'link265')" onMouseOut="HideTip('tt22')">mxCells</a>.&nbsp; The return value should be only be read.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link266 onMouseOver="ShowTip(event, 'tt22', 'link266')" onMouseOut="HideTip('tt22')">mxCell</a> the represents the parent.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getChildVertices"></a>getChildVertices</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getChildVertices = function(</td><td class="PParameter prettyprint " nowrap>parent</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the child vertices of the given parent.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link267 onMouseOver="ShowTip(event, 'tt22', 'link267')" onMouseOut="HideTip('tt22')">mxCell</a> whose child vertices should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getChildEdges"></a>getChildEdges</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getChildEdges = function(</td><td class="PParameter prettyprint " nowrap>parent</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the child edges of the given parent.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link268 onMouseOver="ShowTip(event, 'tt22', 'link268')" onMouseOut="HideTip('tt22')">mxCell</a> whose child edges should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getChildCells"></a>getChildCells</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getChildCells = function(</td><td class="PParameter prettyprint " nowrap>parent,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>vertices,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>edges</td><td class="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><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link269 onMouseOver="ShowTip(event, 'tt22', 'link269')" onMouseOut="HideTip('tt22')">mxCell</a> the represents the parent.</td></tr><tr><td class=CDLEntry>vertices</td><td class=CDLDescription>Boolean indicating if child vertices should be returned.&nbsp; Default is false.</td></tr><tr><td class=CDLEntry>edges</td><td class=CDLDescription>Boolean indicating if child edges should be returned.&nbsp; Default is false.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getTerminal"></a>getTerminal</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getTerminal = function(</td><td class="PParameter prettyprint " nowrap>edge,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>isSource</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the source or target <a href="mxCell-js.html#mxCell" class=LClass id=link270 onMouseOver="ShowTip(event, 'tt22', 'link270')" onMouseOut="HideTip('tt22')">mxCell</a> of the given edge depending on the value of the boolean parameter.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>edge</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link271 onMouseOver="ShowTip(event, 'tt22', 'link271')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the edge.</td></tr><tr><td class=CDLEntry>isSource</td><td class=CDLDescription>Boolean indicating which end of the edge should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.setTerminal"></a>setTerminal</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setTerminal = function(</td><td class="PParameter prettyprint " nowrap>edge,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>terminal,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>isSource</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the source or target terminal of the given <a href="mxCell-js.html#mxCell" class=LClass id=link272 onMouseOver="ShowTip(event, 'tt22', 'link272')" onMouseOut="HideTip('tt22')">mxCell</a> using <a href="#mxTerminalChange" class=LClass id=link273 onMouseOver="ShowTip(event, 'tt56', 'link273')" onMouseOut="HideTip('tt56')">mxTerminalChange</a> and adds the change to the current transaction.&nbsp; This implementation updates the parent of the edge using <a href="#mxGraphModel.updateEdgeParent" class=LFunction id=link274 onMouseOver="ShowTip(event, 'tt40', 'link274')" onMouseOut="HideTip('tt40')">updateEdgeParent</a> if required.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>edge</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link275 onMouseOver="ShowTip(event, 'tt22', 'link275')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the edge.</td></tr><tr><td class=CDLEntry>terminal</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link276 onMouseOver="ShowTip(event, 'tt22', 'link276')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new terminal.</td></tr><tr><td class=CDLEntry>isSource</td><td class=CDLDescription>Boolean indicating if the terminal is the new source or target terminal of the edge.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.setTerminals"></a>setTerminals</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setTerminals = function(</td><td class="PParameter prettyprint " nowrap>edge,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>source,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>target</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the source and target <a href="mxCell-js.html#mxCell" class=LClass id=link277 onMouseOver="ShowTip(event, 'tt22', 'link277')" onMouseOut="HideTip('tt22')">mxCell</a> of the given <a href="mxCell-js.html#mxCell" class=LClass id=link278 onMouseOver="ShowTip(event, 'tt22', 'link278')" onMouseOut="HideTip('tt22')">mxCell</a> in a single transaction using <a href="#mxGraphModel.setTerminal" class=LFunction id=link279 onMouseOver="ShowTip(event, 'tt55', 'link279')" onMouseOut="HideTip('tt55')">setTerminal</a> for each end of the edge.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>edge</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link280 onMouseOver="ShowTip(event, 'tt22', 'link280')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the edge.</td></tr><tr><td class=CDLEntry>source</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link281 onMouseOver="ShowTip(event, 'tt22', 'link281')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new source terminal.</td></tr><tr><td class=CDLEntry>target</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link282 onMouseOver="ShowTip(event, 'tt22', 'link282')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new target terminal.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.terminalForCellChanged"></a>terminalForCellChanged</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.terminalForCellChanged = function(</td><td class="PParameter prettyprint " nowrap>edge,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>terminal,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>isSource</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner helper function to update the terminal of the edge using <a href="mxCell-js.html#mxCell.insertEdge" class=LFunction id=link283 onMouseOver="ShowTip(event, 'tt59', 'link283')" onMouseOut="HideTip('tt59')">mxCell.insertEdge</a> and return the previous terminal.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>edge</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link284 onMouseOver="ShowTip(event, 'tt22', 'link284')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the edge to be updated.</td></tr><tr><td class=CDLEntry>terminal</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link285 onMouseOver="ShowTip(event, 'tt22', 'link285')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the new terminal.</td></tr><tr><td class=CDLEntry>isSource</td><td class=CDLDescription>Boolean indicating if the terminal is the new source or target terminal of the edge.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getEdgeCount"></a>getEdgeCount</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getEdgeCount = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the number of distinct edges connected to the given cell.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link286 onMouseOver="ShowTip(event, 'tt22', 'link286')" onMouseOut="HideTip('tt22')">mxCell</a> that represents the vertex.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getEdgeAt"></a>getEdgeAt</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getEdgeAt = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>index</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the edge of cell at the given index.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link287 onMouseOver="ShowTip(event, 'tt22', 'link287')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the vertex.</td></tr><tr><td class=CDLEntry>index</td><td class=CDLDescription>Integer that specifies the index of the edge to return.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getDirectedEdgeCount"></a>getDirectedEdgeCount</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getDirectedEdgeCount = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>outgoing,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>ignoredEdge</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the number of incoming or outgoing edges, ignoring the given edge.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link288 onMouseOver="ShowTip(event, 'tt22', 'link288')" onMouseOut="HideTip('tt22')">mxCell</a> whose edge count should be returned.</td></tr><tr><td class=CDLEntry>outgoing</td><td class=CDLDescription>Boolean that specifies if the number of outgoing or incoming edges should be returned.</td></tr><tr><td class=CDLEntry>ignoredEdge</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link289 onMouseOver="ShowTip(event, 'tt22', 'link289')" onMouseOut="HideTip('tt22')">mxCell</a> that represents an edge to be ignored.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getConnections"></a>getConnections</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getConnections = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns all edges of the given cell without loops.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link290 onMouseOver="ShowTip(event, 'tt22', 'link290')" onMouseOut="HideTip('tt22')">mxCell</a> whose edges should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getIncomingEdges"></a>getIncomingEdges</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getIncomingEdges = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the incoming edges of the given cell without loops.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link291 onMouseOver="ShowTip(event, 'tt22', 'link291')" onMouseOut="HideTip('tt22')">mxCell</a> whose incoming edges should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getOutgoingEdges"></a>getOutgoingEdges</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getOutgoingEdges = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the outgoing edges of the given cell without loops.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link292 onMouseOver="ShowTip(event, 'tt22', 'link292')" onMouseOut="HideTip('tt22')">mxCell</a> whose outgoing edges should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getEdges"></a>getEdges</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getEdges = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>incoming,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>outgoing,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>includeLoops</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns all distinct edges connected to this cell as a new array of <a href="mxCell-js.html#mxCell" class=LClass id=link293 onMouseOver="ShowTip(event, 'tt22', 'link293')" onMouseOut="HideTip('tt22')">mxCells</a>.&nbsp; 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><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link294 onMouseOver="ShowTip(event, 'tt22', 'link294')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell.</td></tr><tr><td class=CDLEntry>incoming</td><td class=CDLDescription>Optional boolean that specifies if incoming edges should be returned.&nbsp; Default is true.</td></tr><tr><td class=CDLEntry>outgoing</td><td class=CDLDescription>Optional boolean that specifies if outgoing edges should be returned.&nbsp; Default is true.</td></tr><tr><td class=CDLEntry>includeLoops</td><td class=CDLDescription>Optional boolean that specifies if loops should be returned.&nbsp; Default is true.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getEdgesBetween"></a>getEdgesBetween</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getEdgesBetween = function(</td><td class="PParameter prettyprint " nowrap>source,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>target,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>directed</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns all edges between the given source and target pair.&nbsp; 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><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>source</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link295 onMouseOver="ShowTip(event, 'tt22', 'link295')" onMouseOut="HideTip('tt22')">mxCell</a> that defines the source terminal of the edge to be returned.</td></tr><tr><td class=CDLEntry>target</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link296 onMouseOver="ShowTip(event, 'tt22', 'link296')" onMouseOut="HideTip('tt22')">mxCell</a> that defines the target terminal of the edge to be returned.</td></tr><tr><td class=CDLEntry>directed</td><td class=CDLDescription>Optional boolean that specifies if the direction of the edge should be taken into account.&nbsp; Default is false.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getOpposites"></a>getOpposites</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getOpposites = function(</td><td class="PParameter prettyprint " nowrap>edges,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>terminal,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>sources,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>targets</td><td class="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.&nbsp; The result is returned as an array of <a href="mxCell-js.html#mxCell" class=LClass id=link297 onMouseOver="ShowTip(event, 'tt22', 'link297')" onMouseOut="HideTip('tt22')">mxCells</a>.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>edges</td><td class=CDLDescription>Array of <a href="mxCell-js.html#mxCell" class=LClass id=link298 onMouseOver="ShowTip(event, 'tt22', 'link298')" onMouseOut="HideTip('tt22')">mxCells</a> that contain the edges to be examined.</td></tr><tr><td class=CDLEntry>terminal</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link299 onMouseOver="ShowTip(event, 'tt22', 'link299')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the known end of the edges.</td></tr><tr><td class=CDLEntry>sources</td><td class=CDLDescription>Boolean that specifies if source terminals should be contained in the result.&nbsp; Default is true.</td></tr><tr><td class=CDLEntry>targets</td><td class=CDLDescription>Boolean that specifies if target terminals should be contained in the result.&nbsp; Default is true.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getTopmostCells"></a>getTopmostCells</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getTopmostCells = function(</td><td class="PParameter prettyprint " nowrap>cells</td><td class="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 <a href="mxCell-js.html#mxCell" class=LClass id=link300 onMouseOver="ShowTip(event, 'tt22', 'link300')" onMouseOut="HideTip('tt22')">mxCell</a> that it contains.&nbsp; Duplicates should be removed in the cells array to improve performance.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cells</td><td class=CDLDescription>Array of <a href="mxCell-js.html#mxCell" class=LClass id=link301 onMouseOver="ShowTip(event, 'tt22', 'link301')" onMouseOut="HideTip('tt22')">mxCells</a> whose topmost ancestors should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.isVertex"></a>isVertex</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isVertex = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the given cell is a vertex.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link302 onMouseOver="ShowTip(event, 'tt22', 'link302')" onMouseOut="HideTip('tt22')">mxCell</a> that represents the possible vertex.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.isEdge"></a>isEdge</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isEdge = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the given cell is an edge.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link303 onMouseOver="ShowTip(event, 'tt22', 'link303')" onMouseOut="HideTip('tt22')">mxCell</a> that represents the possible edge.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.isConnectable"></a>isConnectable</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isConnectable = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the given <a href="mxCell-js.html#mxCell" class=LClass id=link304 onMouseOver="ShowTip(event, 'tt22', 'link304')" onMouseOut="HideTip('tt22')">mxCell</a> is connectable.&nbsp; If &lt;edgesConnectable&gt; is false, then this function returns false for all edges else it returns the return value of <a href="mxCell-js.html#mxCell.isConnectable" class=LFunction id=link305 onMouseOver="ShowTip(event, 'tt127', 'link305')" onMouseOut="HideTip('tt127')">mxCell.isConnectable</a>.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link306 onMouseOver="ShowTip(event, 'tt22', 'link306')" onMouseOut="HideTip('tt22')">mxCell</a> whose connectable state should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getValue"></a>getValue</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getValue = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the user object of the given <a href="mxCell-js.html#mxCell" class=LClass id=link307 onMouseOver="ShowTip(event, 'tt22', 'link307')" onMouseOut="HideTip('tt22')">mxCell</a> using <a href="mxCell-js.html#mxCell.getValue" class=LFunction id=link308 onMouseOver="ShowTip(event, 'tt74', 'link308')" onMouseOut="HideTip('tt74')">mxCell.getValue</a>.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link309 onMouseOver="ShowTip(event, 'tt22', 'link309')" onMouseOut="HideTip('tt22')">mxCell</a> whose user object should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.setValue"></a>setValue</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setValue = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>value</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the user object of then given <a href="mxCell-js.html#mxCell" class=LClass id=link310 onMouseOver="ShowTip(event, 'tt22', 'link310')" onMouseOut="HideTip('tt22')">mxCell</a> using <a href="#mxValueChange" class=LClass id=link311 onMouseOver="ShowTip(event, 'tt76', 'link311')" onMouseOut="HideTip('tt76')">mxValueChange</a> and adds the change to the current transaction.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link312 onMouseOver="ShowTip(event, 'tt22', 'link312')" onMouseOut="HideTip('tt22')">mxCell</a> whose user object should be changed.</td></tr><tr><td class=CDLEntry>value</td><td class=CDLDescription>Object that defines the new user object.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.valueForCellChanged"></a>valueForCellChanged</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.valueForCellChanged = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>value</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the user object of the given <a href="mxCell-js.html#mxCell" class=LClass id=link313 onMouseOver="ShowTip(event, 'tt22', 'link313')" onMouseOut="HideTip('tt22')">mxCell</a> using <a href="mxCell-js.html#mxCell.valueChanged" class=LFunction id=link314 onMouseOver="ShowTip(event, 'tt78', 'link314')" onMouseOut="HideTip('tt78')">mxCell.valueChanged</a> and return the previous value, that is, the return value of <a href="mxCell-js.html#mxCell.valueChanged" class=LFunction id=link315 onMouseOver="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><pre class="prettyprint">graph.getModel().valueForCellChanged = function(cell, value)
2012-05-21 20:32:26 +00:00
{
var previous = cell.value.getAttribute('label');
cell.value.setAttribute('label', value);
return previous;
};</pre></blockquote></div></div></div>
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getGeometry"></a>getGeometry</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getGeometry = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the <a href="mxGeometry-js.html#mxGeometry" class=LClass id=link316 onMouseOver="ShowTip(event, 'tt80', 'link316')" onMouseOut="HideTip('tt80')">mxGeometry</a> of the given <a href="mxCell-js.html#mxCell" class=LClass id=link317 onMouseOver="ShowTip(event, 'tt22', 'link317')" onMouseOut="HideTip('tt22')">mxCell</a>.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link318 onMouseOver="ShowTip(event, 'tt22', 'link318')" onMouseOut="HideTip('tt22')">mxCell</a> whose geometry should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.setGeometry"></a>setGeometry</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setGeometry = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>geometry</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the <a href="mxGeometry-js.html#mxGeometry" class=LClass id=link319 onMouseOver="ShowTip(event, 'tt80', 'link319')" onMouseOut="HideTip('tt80')">mxGeometry</a> of the given <a href="mxCell-js.html#mxCell" class=LClass id=link320 onMouseOver="ShowTip(event, 'tt22', 'link320')" onMouseOut="HideTip('tt22')">mxCell</a>.&nbsp; The actual update of the cell is carried out in <a href="#mxGraphModel.geometryForCellChanged" class=LFunction id=link321 onMouseOver="ShowTip(event, 'tt82', 'link321')" onMouseOut="HideTip('tt82')">geometryForCellChanged</a>.&nbsp; The <a href="#mxGeometryChange" class=LClass id=link322 onMouseOver="ShowTip(event, 'tt128', 'link322')" onMouseOut="HideTip('tt128')">mxGeometryChange</a> action is used to encapsulate the change.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link323 onMouseOver="ShowTip(event, 'tt22', 'link323')" onMouseOut="HideTip('tt22')">mxCell</a> whose geometry should be changed.</td></tr><tr><td class=CDLEntry>geometry</td><td class=CDLDescription><a href="mxGeometry-js.html#mxGeometry" class=LClass id=link324 onMouseOver="ShowTip(event, 'tt80', 'link324')" onMouseOut="HideTip('tt80')">mxGeometry</a> that defines the new geometry.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.geometryForCellChanged"></a>geometryForCellChanged</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.geometryForCellChanged = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>geometry</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the <a href="mxGeometry-js.html#mxGeometry" class=LClass id=link325 onMouseOver="ShowTip(event, 'tt80', 'link325')" onMouseOut="HideTip('tt80')">mxGeometry</a> of the given <a href="mxCell-js.html#mxCell" class=LClass id=link326 onMouseOver="ShowTip(event, 'tt22', 'link326')" onMouseOut="HideTip('tt22')">mxCell</a> using <a href="mxCell-js.html#mxCell.setGeometry" class=LFunction id=link327 onMouseOver="ShowTip(event, 'tt83', 'link327')" onMouseOut="HideTip('tt83')">mxCell.setGeometry</a> and return the previous <a href="mxGeometry-js.html#mxGeometry" class=LClass id=link328 onMouseOver="ShowTip(event, 'tt80', 'link328')" onMouseOut="HideTip('tt80')">mxGeometry</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getStyle"></a>getStyle</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getStyle = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns the style of the given <a href="mxCell-js.html#mxCell" class=LClass id=link329 onMouseOver="ShowTip(event, 'tt22', 'link329')" onMouseOut="HideTip('tt22')">mxCell</a>.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link330 onMouseOver="ShowTip(event, 'tt22', 'link330')" onMouseOut="HideTip('tt22')">mxCell</a> whose style should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.setStyle"></a>setStyle</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setStyle = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>style</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the style of the given <a href="mxCell-js.html#mxCell" class=LClass id=link331 onMouseOver="ShowTip(event, 'tt22', 'link331')" onMouseOut="HideTip('tt22')">mxCell</a> using <a href="#mxStyleChange" class=LClass id=link332 onMouseOver="ShowTip(event, 'tt86', 'link332')" onMouseOut="HideTip('tt86')">mxStyleChange</a> and adds the change to the current transaction.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link333 onMouseOver="ShowTip(event, 'tt22', 'link333')" onMouseOut="HideTip('tt22')">mxCell</a> whose style should be changed.</td></tr><tr><td class=CDLEntry>style</td><td class=CDLDescription>String of the form [stylename;|key=value;] to specify the new cell style.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.styleForCellChanged"></a>styleForCellChanged</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.styleForCellChanged = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>style</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the style of the given <a href="mxCell-js.html#mxCell" class=LClass id=link334 onMouseOver="ShowTip(event, 'tt22', 'link334')" onMouseOut="HideTip('tt22')">mxCell</a> using <a href="mxCell-js.html#mxCell.setStyle" class=LFunction id=link335 onMouseOver="ShowTip(event, 'tt88', 'link335')" onMouseOut="HideTip('tt88')">mxCell.setStyle</a> and return the previous style.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link336 onMouseOver="ShowTip(event, 'tt22', 'link336')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell to be updated.</td></tr><tr><td class=CDLEntry>style</td><td class=CDLDescription>String of the form [stylename;|key=value;] to specify the new cell style.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.isCollapsed"></a>isCollapsed</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isCollapsed = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the given <a href="mxCell-js.html#mxCell" class=LClass id=link337 onMouseOver="ShowTip(event, 'tt22', 'link337')" onMouseOut="HideTip('tt22')">mxCell</a> is collapsed.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link338 onMouseOver="ShowTip(event, 'tt22', 'link338')" onMouseOut="HideTip('tt22')">mxCell</a> whose collapsed state should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.setCollapsed"></a>setCollapsed</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setCollapsed = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>collapsed</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the collapsed state of the given <a href="mxCell-js.html#mxCell" class=LClass id=link339 onMouseOver="ShowTip(event, 'tt22', 'link339')" onMouseOut="HideTip('tt22')">mxCell</a> using <a href="#mxCollapseChange" class=LClass id=link340 onMouseOver="ShowTip(event, 'tt91', 'link340')" onMouseOut="HideTip('tt91')">mxCollapseChange</a> and adds the change to the current transaction.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link341 onMouseOver="ShowTip(event, 'tt22', 'link341')" onMouseOut="HideTip('tt22')">mxCell</a> whose collapsed state should be changed.</td></tr><tr><td class=CDLEntry>collapsed</td><td class=CDLDescription>Boolean that specifies the new collpased state.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.collapsedStateForCellChanged"></a>collapsedStateForCellChanged</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.collapsedStateForCellChanged = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>collapsed</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the collapsed state of the given <a href="mxCell-js.html#mxCell" class=LClass id=link342 onMouseOver="ShowTip(event, 'tt22', 'link342')" onMouseOut="HideTip('tt22')">mxCell</a> using <a href="mxCell-js.html#mxCell.setCollapsed" class=LFunction id=link343 onMouseOver="ShowTip(event, 'tt93', 'link343')" onMouseOut="HideTip('tt93')">mxCell.setCollapsed</a> and return the previous collapsed state.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link344 onMouseOver="ShowTip(event, 'tt22', 'link344')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell to be updated.</td></tr><tr><td class=CDLEntry>collapsed</td><td class=CDLDescription>Boolean that specifies the new collpased state.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.isVisible"></a>isVisible</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.isVisible = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns true if the given <a href="mxCell-js.html#mxCell" class=LClass id=link345 onMouseOver="ShowTip(event, 'tt22', 'link345')" onMouseOut="HideTip('tt22')">mxCell</a> is visible.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link346 onMouseOver="ShowTip(event, 'tt22', 'link346')" onMouseOut="HideTip('tt22')">mxCell</a> whose visible state should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.setVisible"></a>setVisible</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.setVisible = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>visible</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Sets the visible state of the given <a href="mxCell-js.html#mxCell" class=LClass id=link347 onMouseOver="ShowTip(event, 'tt22', 'link347')" onMouseOut="HideTip('tt22')">mxCell</a> using <a href="#mxVisibleChange" class=LClass id=link348 onMouseOver="ShowTip(event, 'tt96', 'link348')" onMouseOut="HideTip('tt96')">mxVisibleChange</a> and adds the change to the current transaction.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link349 onMouseOver="ShowTip(event, 'tt22', 'link349')" onMouseOut="HideTip('tt22')">mxCell</a> whose visible state should be changed.</td></tr><tr><td class=CDLEntry>visible</td><td class=CDLDescription>Boolean that specifies the new visible state.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.visibleStateForCellChanged"></a>visibleStateForCellChanged</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.visibleStateForCellChanged = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>visible</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner callback to update the visible state of the given <a href="mxCell-js.html#mxCell" class=LClass id=link350 onMouseOver="ShowTip(event, 'tt22', 'link350')" onMouseOut="HideTip('tt22')">mxCell</a> using <a href="mxCell-js.html#mxCell.setCollapsed" class=LFunction id=link351 onMouseOver="ShowTip(event, 'tt93', 'link351')" onMouseOut="HideTip('tt93')">mxCell.setCollapsed</a> and return the previous visible state.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link352 onMouseOver="ShowTip(event, 'tt22', 'link352')" onMouseOut="HideTip('tt22')">mxCell</a> that specifies the cell to be updated.</td></tr><tr><td class=CDLEntry>visible</td><td class=CDLDescription>Boolean that specifies the new visible state.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.execute"></a>execute</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.execute = function(</td><td class="PParameter prettyprint " nowrap>change</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Executes the given edit and fires events if required.&nbsp; The edit object requires an execute function which is invoked.&nbsp; The edit is added to the <a href="#mxGraphModel.currentEdit" class=LVariable id=link353 onMouseOver="ShowTip(event, 'tt15', 'link353')" onMouseOut="HideTip('tt15')">currentEdit</a> between <a href="#mxGraphModel.beginUpdate" class=LFunction id=link354 onMouseOver="ShowTip(event, 'tt4', 'link354')" onMouseOut="HideTip('tt4')">beginUpdate</a> and <a href="#mxGraphModel.endUpdate" class=LFunction id=link355 onMouseOver="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 <a href="#mxGraphModel.beginUpdate" class=LFunction id=link356 onMouseOver="ShowTip(event, 'tt4', 'link356')" onMouseOut="HideTip('tt4')">beginUpdate</a> calls have been made without calling <a href="#mxGraphModel.endUpdate" class=LFunction id=link357 onMouseOver="ShowTip(event, 'tt5', 'link357')" onMouseOut="HideTip('tt5')">endUpdate</a>.&nbsp; This implementation fires an <a href="#mxGraphModel.execute" class=LFunction id=link358 onMouseOver="ShowTip(event, 'tt98', 'link358')" onMouseOut="HideTip('tt98')">execute</a> event before executing the given change.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>change</td><td class=CDLDescription>Object that described the change.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.beginUpdate"></a>beginUpdate</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.beginUpdate = function()</td></tr></table></blockquote><p>Increments the <a href="#mxGraphModel.updateLevel" class=LVariable id=link359 onMouseOver="ShowTip(event, 'tt3', 'link359')" onMouseOut="HideTip('tt3')">updateLevel</a> by one.&nbsp; The event notification is queued until <a href="#mxGraphModel.updateLevel" class=LVariable id=link360 onMouseOver="ShowTip(event, 'tt3', 'link360')" onMouseOut="HideTip('tt3')">updateLevel</a> reaches 0 by use of <a href="#mxGraphModel.endUpdate" class=LFunction id=link361 onMouseOver="ShowTip(event, 'tt5', 'link361')" onMouseOut="HideTip('tt5')">endUpdate</a>.</p><p>All changes on <a href="#mxGraphModel.mxGraphModel" class=LFunction id=link362 onMouseOver="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).&nbsp; 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 <a href="#mxGraphModel.beginUpdate" class=LFunction id=link363 onMouseOver="ShowTip(event, 'tt4', 'link363')" onMouseOut="HideTip('tt4')">beginUpdate</a> and <a href="#mxGraphModel.endUpdate" class=LFunction id=link364 onMouseOver="ShowTip(event, 'tt5', 'link364')" onMouseOut="HideTip('tt5')">endUpdate</a> calls as shown here:</p><blockquote><pre class="prettyprint">var model = graph.getModel();
2012-05-21 20:32:26 +00:00
var parent = graph.getDefaultParent();
var index = model.getChildCount(parent);
model.beginUpdate();
try
{
model.add(parent, v1, index);
model.add(parent, v2, index+1);
}
finally
{
model.endUpdate();
}</pre></blockquote><p>Of course there is a shortcut for appending a sequence of cells into the default parent:</p><blockquote><pre class="prettyprint">graph.addCells([v1, v2]).</pre></blockquote></div></div></div>
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.endUpdate"></a>endUpdate</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.endUpdate = function()</td></tr></table></blockquote><p>Decrements the <a href="#mxGraphModel.updateLevel" class=LVariable id=link365 onMouseOver="ShowTip(event, 'tt3', 'link365')" onMouseOut="HideTip('tt3')">updateLevel</a> by one and fires an &lt;undo&gt; event if the <a href="#mxGraphModel.updateLevel" class=LVariable id=link366 onMouseOver="ShowTip(event, 'tt3', 'link366')" onMouseOut="HideTip('tt3')">updateLevel</a> reaches 0.&nbsp; This function indirectly fires a &lt;change&gt; event by invoking the notify function on the <a href="#mxGraphModel.currentEdit" class=LVariable id=link367 onMouseOver="ShowTip(event, 'tt15', 'link367')" onMouseOut="HideTip('tt15')">currentEdit</a> und then creates a new <a href="#mxGraphModel.currentEdit" class=LVariable id=link368 onMouseOver="ShowTip(event, 'tt15', 'link368')" onMouseOut="HideTip('tt15')">currentEdit</a> using <a href="#mxGraphModel.createUndoableEdit" class=LFunction id=link369 onMouseOver="ShowTip(event, 'tt99', 'link369')" onMouseOut="HideTip('tt99')">createUndoableEdit</a>.</p><p>The &lt;undo&gt; event is fired only once per edit, whereas the &lt;change&gt; event is fired whenever the notify function is invoked, that is, on undo and redo of the edit.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.createUndoableEdit"></a>createUndoableEdit</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.createUndoableEdit = function()</td></tr></table></blockquote><p>Creates a new <a href="../util/mxUndoableEdit-js.html#mxUndoableEdit" class=LClass id=link370 onMouseOver="ShowTip(event, 'tt100', 'link370')" onMouseOut="HideTip('tt100')">mxUndoableEdit</a> that implements the notify function to fire a &lt;change&gt; and &lt;notify&gt; event through the <a href="../util/mxUndoableEdit-js.html#mxUndoableEdit" class=LClass id=link371 onMouseOver="ShowTip(event, 'tt100', 'link371')" onMouseOut="HideTip('tt100')">mxUndoableEdit</a>&rsquo;s source.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.mergeChildren"></a>mergeChildren</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.mergeChildren = function(</td><td class="PParameter prettyprint " nowrap>from,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>to,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>cloneAllEdges</td><td class="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.&nbsp; 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.&nbsp; 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>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.mergeChildren"></a>mergeChildren</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.mergeChildrenImpl = function(</td><td class="PParameter prettyprint " nowrap>from,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>to,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>cloneAllEdges,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>mapping</td><td class="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>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.getParents"></a>getParents</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.getParents = function(</td><td class="PParameter prettyprint " nowrap>cells</td><td class="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><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cells</td><td class=CDLDescription>Array of cells whose parents should be returned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.cloneCell"></a>cloneCell</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.cloneCell = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns a deep clone of the given <a href="mxCell-js.html#mxCell" class=LClass id=link372 onMouseOver="ShowTip(event, 'tt22', 'link372')" onMouseOut="HideTip('tt22')">mxCell</a> (including the children) which is created using <a href="#mxGraphModel.cloneCells" class=LFunction id=link373 onMouseOver="ShowTip(event, 'tt104', 'link373')" onMouseOut="HideTip('tt104')">cloneCells</a>.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cell</td><td class=CDLDescription><a href="mxCell-js.html#mxCell" class=LClass id=link374 onMouseOver="ShowTip(event, 'tt22', 'link374')" onMouseOut="HideTip('tt22')">mxCell</a> to be cloned.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.cloneCells"></a>cloneCells</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.cloneCells = function(</td><td class="PParameter prettyprint " nowrap>cells,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>includeChildren,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>mapping</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Returns an array of clones for the given array of <a href="mxCell-js.html#mxCell" class=LClass id=link375 onMouseOver="ShowTip(event, 'tt22', 'link375')" onMouseOut="HideTip('tt22')">mxCells</a>.&nbsp; Depending on the value of includeChildren, a deep clone is created for each cell.&nbsp; Connections are restored based if the corresponding cell is contained in the passed in array.</p><h4 class=CHeading>Parameters</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>cells</td><td class=CDLDescription>Array of <a href="mxCell-js.html#mxCell" class=LClass id=link376 onMouseOver="ShowTip(event, 'tt22', 'link376')" onMouseOut="HideTip('tt22')">mxCell</a> to be cloned.</td></tr><tr><td class=CDLEntry>includeChildren</td><td class=CDLDescription>Boolean indicating if the cells should be cloned with all descendants.</td></tr><tr><td class=CDLEntry>mapping</td><td class=CDLDescription>Optional mapping for existing clones.</td></tr></table></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.cloneCellImpl"></a>cloneCellImpl</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.cloneCellImpl = function(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>mapping,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>includeChildren</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Inner helper method for cloning cells recursively.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.cellCloned"></a>cellCloned</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.cellCloned = function(</td><td class="PParameter prettyprint " nowrap>cell</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote><p>Hook for cloning the cell.&nbsp; This returns cell.clone() or any possible exceptions.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGraphModel.restoreClone"></a>restoreClone</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>mxGraphModel.prototype.restoreClone = function(</td><td class="PParameter prettyprint " nowrap>clone,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>mapping</td><td class="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>
2012-05-21 20:32:26 +00:00
2016-04-13 07:03:38 +00:00
<div class="CClass"><div class=CTopic><h2 class=CTitle><a name="mxRootChange"></a>mxRootChange</h2><div class=CBody><p>Action to change the root in a model.</p><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SGroup"><td class=SEntry><a href="#mxRootChange.Functions" >Functions</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent1 SMarked"><td class=SEntry><a href="#mxRootChange.mxRootChange" id=link377 onMouseOver="ShowTip(event, 'tt108', 'link377')" onMouseOut="HideTip('tt108')">mxRootChange</a></td><td class=SDescription>Constructs a change of the root in the specified model.</td></tr><tr class="SFunction SIndent1"><td class=SEntry><a href="#mxRootChange.execute" id=link378 onMouseOver="ShowTip(event, 'tt109', 'link378')" onMouseOut="HideTip('tt109')">execute</a></td><td class=SDescription>Carries out a change of the root using <a href="#mxGraphModel.rootChanged" class=LFunction id=link379 onMouseOver="ShowTip(event, 'tt29', 'link379')" onMouseOut="HideTip('tt29')">mxGraphModel.rootChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxRootChange.Functions"></a>Functions</h3></div></div>
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxRootChange.mxRootChange"></a>mxRootChange</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>function mxRootChange(</td><td class="PParameter prettyprint " nowrap>model,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>root</td><td class="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>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxRootChange.execute"></a>execute</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxRootChange.prototype.execute = function()</td></tr></table></blockquote><p>Carries out a change of the root using <a href="#mxGraphModel.rootChanged" class=LFunction id=link380 onMouseOver="ShowTip(event, 'tt29', 'link380')" onMouseOut="HideTip('tt29')">mxGraphModel.rootChanged</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2016-04-13 07:03:38 +00:00
<div class="CClass"><div class=CTopic><h2 class=CTitle><a name="mxChildChange"></a>mxChildChange</h2><div class=CBody><p>Action to add or remove a child in a model.</p><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SGroup"><td class=SEntry><a href="#mxChildChange.Functions" >Functions</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent1 SMarked"><td class=SEntry><a href="#mxChildChange.mxChildChange" id=link381 onMouseOver="ShowTip(event, 'tt110', 'link381')" onMouseOut="HideTip('tt110')">mxChildChange</a></td><td class=SDescription>Constructs a change of a child in the specified model.</td></tr><tr class="SFunction SIndent1"><td class=SEntry><a href="#mxChildChange.execute" id=link382 onMouseOver="ShowTip(event, 'tt111', 'link382')" onMouseOut="HideTip('tt111')">execute</a></td><td class=SDescription>Changes the parent of &lt;child&gt; using <a href="#mxGraphModel.parentForCellChanged" class=LFunction id=link383 onMouseOver="ShowTip(event, 'tt46', 'link383')" onMouseOut="HideTip('tt46')">mxGraphModel.parentForCellChanged</a> and removes or restores the cell&rsquo;s connections.</td></tr><tr class="SFunction SIndent1 SMarked"><td class=SEntry><a href="#mxChildChange.disconnect" >disconnect</a></td><td class=SDescription>Disconnects the given cell recursively from its terminals and stores the previous terminal in the cell&rsquo;s terminals.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxChildChange.Functions"></a>Functions</h3></div></div>
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxChildChange.mxChildChange"></a>mxChildChange</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>function mxChildChange(</td><td class="PParameter prettyprint " nowrap>model,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>parent,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>child,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>index</td><td class="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>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxChildChange.execute"></a>execute</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxChildChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the parent of &lt;child&gt; using <a href="#mxGraphModel.parentForCellChanged" class=LFunction id=link384 onMouseOver="ShowTip(event, 'tt46', 'link384')" onMouseOut="HideTip('tt46')">mxGraphModel.parentForCellChanged</a> and removes or restores the cell&rsquo;s connections.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxChildChange.disconnect"></a>disconnect</h3><div class=CBody><p>Disconnects the given cell recursively from its terminals and stores the previous terminal in the cell&rsquo;s terminals.</p></div></div></div>
2016-04-13 07:03:38 +00:00
<div class="CClass"><div class=CTopic><h2 class=CTitle><a name="mxTerminalChange"></a>mxTerminalChange</h2><div class=CBody><p>Action to change a terminal in a model.</p><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SGroup"><td class=SEntry><a href="#mxTerminalChange.Functions" >Functions</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent1 SMarked"><td class=SEntry><a href="#mxTerminalChange.mxTerminalChange" id=link385 onMouseOver="ShowTip(event, 'tt112', 'link385')" onMouseOut="HideTip('tt112')">mxTerminalChange</a></td><td class=SDescription>Constructs a change of a terminal in the specified model.</td></tr><tr class="SFunction SIndent1"><td class=SEntry><a href="#mxTerminalChange.execute" id=link386 onMouseOver="ShowTip(event, 'tt113', 'link386')" onMouseOut="HideTip('tt113')">execute</a></td><td class=SDescription>Changes the terminal of &lt;cell&gt; to &lt;previous&gt; using <a href="#mxGraphModel.terminalForCellChanged" class=LFunction id=link387 onMouseOver="ShowTip(event, 'tt58', 'link387')" onMouseOut="HideTip('tt58')">mxGraphModel.terminalForCellChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxTerminalChange.Functions"></a>Functions</h3></div></div>
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxTerminalChange.mxTerminalChange"></a>mxTerminalChange</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>function mxTerminalChange(</td><td class="PParameter prettyprint " nowrap>model,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>terminal,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>source</td><td class="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>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxTerminalChange.execute"></a>execute</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxTerminalChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the terminal of &lt;cell&gt; to &lt;previous&gt; using <a href="#mxGraphModel.terminalForCellChanged" class=LFunction id=link388 onMouseOver="ShowTip(event, 'tt58', 'link388')" onMouseOut="HideTip('tt58')">mxGraphModel.terminalForCellChanged</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2016-04-13 07:03:38 +00:00
<div class="CClass"><div class=CTopic><h2 class=CTitle><a name="mxValueChange"></a>mxValueChange</h2><div class=CBody><p>Action to change a user object in a model.</p><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SGroup"><td class=SEntry><a href="#mxValueChange.Functions" >Functions</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent1 SMarked"><td class=SEntry><a href="#mxValueChange.mxValueChange" id=link389 onMouseOver="ShowTip(event, 'tt114', 'link389')" onMouseOut="HideTip('tt114')">mxValueChange</a></td><td class=SDescription>Constructs a change of a user object in the specified model.</td></tr><tr class="SFunction SIndent1"><td class=SEntry><a href="#mxValueChange.execute" id=link390 onMouseOver="ShowTip(event, 'tt115', 'link390')" onMouseOut="HideTip('tt115')">execute</a></td><td class=SDescription>Changes the value of &lt;cell&gt; to &lt;previous&gt; using <a href="#mxGraphModel.valueForCellChanged" class=LFunction id=link391 onMouseOver="ShowTip(event, 'tt77', 'link391')" onMouseOut="HideTip('tt77')">mxGraphModel.valueForCellChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxValueChange.Functions"></a>Functions</h3></div></div>
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxValueChange.mxValueChange"></a>mxValueChange</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>function mxValueChange(</td><td class="PParameter prettyprint " nowrap>model,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>value</td><td class="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>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxValueChange.execute"></a>execute</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxValueChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the value of &lt;cell&gt; to &lt;previous&gt; using <a href="#mxGraphModel.valueForCellChanged" class=LFunction id=link392 onMouseOver="ShowTip(event, 'tt77', 'link392')" onMouseOut="HideTip('tt77')">mxGraphModel.valueForCellChanged</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2016-04-13 07:03:38 +00:00
<div class="CClass"><div class=CTopic><h2 class=CTitle><a name="mxStyleChange"></a>mxStyleChange</h2><div class=CBody><p>Action to change a cell&rsquo;s style in a model.</p><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SGroup"><td class=SEntry><a href="#mxStyleChange.Functions" >Functions</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent1 SMarked"><td class=SEntry><a href="#mxStyleChange.mxStyleChange" id=link393 onMouseOver="ShowTip(event, 'tt116', 'link393')" onMouseOut="HideTip('tt116')">mxStyleChange</a></td><td class=SDescription>Constructs a change of a style in the specified model.</td></tr><tr class="SFunction SIndent1"><td class=SEntry><a href="#mxStyleChange.execute" id=link394 onMouseOver="ShowTip(event, 'tt117', 'link394')" onMouseOut="HideTip('tt117')">execute</a></td><td class=SDescription>Changes the style of &lt;cell&gt; to &lt;previous&gt; using <a href="#mxGraphModel.styleForCellChanged" class=LFunction id=link395 onMouseOver="ShowTip(event, 'tt87', 'link395')" onMouseOut="HideTip('tt87')">mxGraphModel.styleForCellChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxStyleChange.Functions"></a>Functions</h3></div></div>
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxStyleChange.mxStyleChange"></a>mxStyleChange</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>function mxStyleChange(</td><td class="PParameter prettyprint " nowrap>model,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>style</td><td class="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>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxStyleChange.execute"></a>execute</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxStyleChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the style of &lt;cell&gt; to &lt;previous&gt; using <a href="#mxGraphModel.styleForCellChanged" class=LFunction id=link396 onMouseOver="ShowTip(event, 'tt87', 'link396')" onMouseOut="HideTip('tt87')">mxGraphModel.styleForCellChanged</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2016-04-13 07:03:38 +00:00
<div class="CClass"><div class=CTopic><h2 class=CTitle><a name="mxGeometryChange"></a>mxGeometryChange</h2><div class=CBody><p>Action to change a cell&rsquo;s geometry in a model.</p><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SGroup"><td class=SEntry><a href="#mxGeometryChange.Functions" >Functions</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent1 SMarked"><td class=SEntry><a href="#mxGeometryChange.mxGeometryChange" id=link397 onMouseOver="ShowTip(event, 'tt118', 'link397')" onMouseOut="HideTip('tt118')">mxGeometryChange</a></td><td class=SDescription>Constructs a change of a geometry in the specified model.</td></tr><tr class="SFunction SIndent1"><td class=SEntry><a href="#mxGeometryChange.execute" id=link398 onMouseOver="ShowTip(event, 'tt119', 'link398')" onMouseOut="HideTip('tt119')">execute</a></td><td class=SDescription>Changes the geometry of &lt;cell&gt; ro &lt;previous&gt; using <a href="#mxGraphModel.geometryForCellChanged" class=LFunction id=link399 onMouseOver="ShowTip(event, 'tt82', 'link399')" onMouseOut="HideTip('tt82')">mxGraphModel.geometryForCellChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxGeometryChange.Functions"></a>Functions</h3></div></div>
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGeometryChange.mxGeometryChange"></a>mxGeometryChange</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>function mxGeometryChange(</td><td class="PParameter prettyprint " nowrap>model,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>geometry</td><td class="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>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxGeometryChange.execute"></a>execute</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGeometryChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the geometry of &lt;cell&gt; ro &lt;previous&gt; using <a href="#mxGraphModel.geometryForCellChanged" class=LFunction id=link400 onMouseOver="ShowTip(event, 'tt82', 'link400')" onMouseOut="HideTip('tt82')">mxGraphModel.geometryForCellChanged</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2016-04-13 07:03:38 +00:00
<div class="CClass"><div class=CTopic><h2 class=CTitle><a name="mxCollapseChange"></a>mxCollapseChange</h2><div class=CBody><p>Action to change a cell&rsquo;s collapsed state in a model.</p><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SGroup"><td class=SEntry><a href="#mxCollapseChange.Functions" >Functions</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent1 SMarked"><td class=SEntry><a href="#mxCollapseChange.mxCollapseChange" id=link401 onMouseOver="ShowTip(event, 'tt120', 'link401')" onMouseOut="HideTip('tt120')">mxCollapseChange</a></td><td class=SDescription>Constructs a change of a collapsed state in the specified model.</td></tr><tr class="SFunction SIndent1"><td class=SEntry><a href="#mxCollapseChange.execute" id=link402 onMouseOver="ShowTip(event, 'tt121', 'link402')" onMouseOut="HideTip('tt121')">execute</a></td><td class=SDescription>Changes the collapsed state of &lt;cell&gt; to &lt;previous&gt; using <a href="#mxGraphModel.collapsedStateForCellChanged" class=LFunction id=link403 onMouseOver="ShowTip(event, 'tt92', 'link403')" onMouseOut="HideTip('tt92')">mxGraphModel.collapsedStateForCellChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxCollapseChange.Functions"></a>Functions</h3></div></div>
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxCollapseChange.mxCollapseChange"></a>mxCollapseChange</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>function mxCollapseChange(</td><td class="PParameter prettyprint " nowrap>model,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>collapsed</td><td class="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>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxCollapseChange.execute"></a>execute</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxCollapseChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the collapsed state of &lt;cell&gt; to &lt;previous&gt; using <a href="#mxGraphModel.collapsedStateForCellChanged" class=LFunction id=link404 onMouseOver="ShowTip(event, 'tt92', 'link404')" onMouseOut="HideTip('tt92')">mxGraphModel.collapsedStateForCellChanged</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2016-04-13 07:03:38 +00:00
<div class="CClass"><div class=CTopic><h2 class=CTitle><a name="mxVisibleChange"></a>mxVisibleChange</h2><div class=CBody><p>Action to change a cell&rsquo;s visible state in a model.</p><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SGroup"><td class=SEntry><a href="#mxVisibleChange.Functions" >Functions</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent1 SMarked"><td class=SEntry><a href="#mxVisibleChange.mxVisibleChange" id=link405 onMouseOver="ShowTip(event, 'tt122', 'link405')" onMouseOut="HideTip('tt122')">mxVisibleChange</a></td><td class=SDescription>Constructs a change of a visible state in the specified model.</td></tr><tr class="SFunction SIndent1"><td class=SEntry><a href="#mxVisibleChange.execute" id=link406 onMouseOver="ShowTip(event, 'tt123', 'link406')" onMouseOut="HideTip('tt123')">execute</a></td><td class=SDescription>Changes the visible state of &lt;cell&gt; to &lt;previous&gt; using <a href="#mxGraphModel.visibleStateForCellChanged" class=LFunction id=link407 onMouseOver="ShowTip(event, 'tt97', 'link407')" onMouseOut="HideTip('tt97')">mxGraphModel.visibleStateForCellChanged</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxVisibleChange.Functions"></a>Functions</h3></div></div>
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxVisibleChange.mxVisibleChange"></a>mxVisibleChange</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>function mxVisibleChange(</td><td class="PParameter prettyprint " nowrap>model,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>visible</td><td class="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>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxVisibleChange.execute"></a>execute</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxVisibleChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the visible state of &lt;cell&gt; to &lt;previous&gt; using <a href="#mxGraphModel.visibleStateForCellChanged" class=LFunction id=link408 onMouseOver="ShowTip(event, 'tt97', 'link408')" onMouseOut="HideTip('tt97')">mxGraphModel.visibleStateForCellChanged</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CClass"><div class=CTopic><h2 class=CTitle><a name="mxCellAttributeChange"></a>mxCellAttributeChange</h2><div class=CBody><p>Action to change the attribute of a cell&rsquo;s user object.&nbsp; There is no method on the graph model that uses this action.&nbsp; To use the action, you can use the code shown in the example below.</p><h4 class=CHeading>Example</h4><p>To change the attributeName in the cell&rsquo;s user object to attributeValue, use the following code:</p><blockquote><pre class="prettyprint">model.beginUpdate();
try
{
var edit = new mxCellAttributeChange(
cell, attributeName, attributeValue);
model.execute(edit);
}
finally
{
model.endUpdate();
2016-04-13 07:03:38 +00:00
}</pre></blockquote><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SGroup"><td class=SEntry><a href="#mxCellAttributeChange.Functions" >Functions</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent1 SMarked"><td class=SEntry><a href="#mxCellAttributeChange.mxCellAttributeChange" id=link409 onMouseOver="ShowTip(event, 'tt124', 'link409')" onMouseOut="HideTip('tt124')">mxCellAttributeChange</a></td><td class=SDescription>Constructs a change of a attribute of the DOM node stored as the value of the given <a href="mxCell-js.html#mxCell" class=LClass id=link410 onMouseOver="ShowTip(event, 'tt22', 'link410')" onMouseOut="HideTip('tt22')">mxCell</a>.</td></tr><tr class="SFunction SIndent1"><td class=SEntry><a href="#mxCellAttributeChange.execute" id=link411 onMouseOver="ShowTip(event, 'tt125', 'link411')" onMouseOut="HideTip('tt125')">execute</a></td><td class=SDescription>Changes the attribute of the cell&rsquo;s user object by using <a href="mxCell-js.html#mxCell.setAttribute" class=LFunction id=link412 onMouseOver="ShowTip(event, 'tt126', 'link412')" onMouseOut="HideTip('tt126')">mxCell.setAttribute</a>.</td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
2012-05-21 20:32:26 +00:00
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="mxCellAttributeChange.Functions"></a>Functions</h3></div></div>
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxCellAttributeChange.mxCellAttributeChange"></a>mxCellAttributeChange</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>function mxCellAttributeChange(</td><td class="PParameter prettyprint " nowrap>cell,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>attribute,</td></tr><tr><td></td><td class="PParameter prettyprint " nowrap>value</td><td class="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 <a href="mxCell-js.html#mxCell" class=LClass id=link413 onMouseOver="ShowTip(event, 'tt22', 'link413')" onMouseOut="HideTip('tt22')">mxCell</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
2017-06-27 11:43:19 +00:00
<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="mxCellAttributeChange.execute"></a>execute</h3><div class=CBody><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxCellAttributeChange.prototype.execute = function()</td></tr></table></blockquote><p>Changes the attribute of the cell&rsquo;s user object by using <a href="mxCell-js.html#mxCell.setAttribute" class=LFunction id=link414 onMouseOver="ShowTip(event, 'tt126', 'link414')" onMouseOut="HideTip('tt126')">mxCell.setAttribute</a>.</p></div></div></div>
2012-05-21 20:32:26 +00:00
</div><!--Content-->
<div id=Footer><a href="http://www.naturaldocs.org">Generated by Natural Docs</a></div><!--Footer-->
2017-04-12 12:48:34 +00:00
<div id=Menu><div class=MEntry><div class=MFile><a href="../index-txt.html">API Specification</a></div></div><div class=MEntry><div class=MGroup><a href="javascript:ToggleMenu('MGroupContent1')">Editor</a><div class=MGroupContent id=MGroupContent1><div class=MEntry><div class=MFile><a href="../editor/mxDefaultKeyHandler-js.html">mxDefaultKeyHandler</a></div></div><div class=MEntry><div class=MFile><a href="../editor/mxDefaultPopupMenu-js.html">mxDefaultPopupMenu</a></div></div><div class=MEntry><div class=MFile><a href="../editor/mxDefaultToolbar-js.html">mxDefaultToolbar</a></div></div><div class=MEntry><div class=MFile><a href="../editor/mxEditor-js.html">mxEditor</a></div></div></div></div></div><div class=MEntry><div class=MGroup><a href="javascript:ToggleMenu('MGroupContent2')">Handler</a><div class=MGroupContent id=MGroupContent2><div class=MEntry><div class=MFile><a href="../handler/mxCellHighlight-js.html">mxCellHighlight</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxCellMarker-js.html">mxCellMarker</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxCellTracker-js.html">mxCellTracker</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxConnectionHandler-js.html">mxConnectionHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxConstraintHandler-js.html">mxConstraintHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxEdgeHandler-js.html">mxEdgeHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxEdgeSegmentHandler-js.html">mxEdgeSegmentHandler.js</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxElbowEdgeHandler-js.html">mxElbowEdgeHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxGraphHandler-js.html">mxGraphHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxHandle-js.html">mxHandle</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxKeyHandler-js.html">mxKeyHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxPanningHandler-js.html">mxPanningHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxPopupMenuHandler-js.html">mxPopupMenuHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxRubberband-js.html">mxRubberband</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxSelectionCellsHandler-js.html">mxSelectionCellsHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxTooltipHandler-js.html">mxTooltipHandler</a></div></div><div class=MEntry><div class=MFile><a href="../handler/mxVertexHandler-js.html">mxVertexHandler</a></div></div></div></div></div><div class=MEntry><div class=MGroup><a href="javascript:ToggleMenu('MGroupContent3')">Io</a><div class=MGroupContent id=MGroupContent3><div class=MEntry><div class=MFile><a href="../io/mxCellCodec-js.html">mxCellCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxChildChangeCodec-js.html">mxChildChangeCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxCodec-js.html">mxCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxCodecRegistry-js.html">mxCodecRegistry</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxDefaultKeyHandlerCodec-js.html">mxDefaultKeyHandlerCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxDefaultPopupMenuCodec-js.html">mxDefaultPopupMenuCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxDefaultToolbarCodec-js.html">mxDefaultToolbarCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxEditorCodec-js.html">mxEditorCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxGenericChangeCodec-js.html">mxGenericChangeCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxGraphCodec-js.html">mxGraphCodec</a></div></div><div class=MEntry><div class=MFile><a href="../io/mxGraphViewCodec-js.html">mxGraphViewCodec</a></di
2012-05-21 20:32:26 +00:00
var searchPanel = new SearchPanel("searchPanel", "HTML", "../../search");
--></script><div id=MSearchPanel class=MSearchPanelInactive><input type=text id=MSearchField value=Search onFocus="searchPanel.OnSearchFieldFocus(true)" onBlur="searchPanel.OnSearchFieldFocus(false)" onKeyUp="searchPanel.OnSearchFieldChange()"><select id=MSearchType onFocus="searchPanel.OnSearchTypeFocus(true)" onBlur="searchPanel.OnSearchTypeFocus(false)" onChange="searchPanel.OnSearchTypeChange()"><option id=MSearchEverything selected value="General">Everything</option><option value="Classes">Classes</option><option value="Cookies">Cookies</option><option value="Events">Events</option><option value="Files">Files</option><option value="Functions">Functions</option><option value="Variables">Variables</option></select></div><script language=JavaScript><!--
2014-07-25 06:48:01 +00:00
HideAllBut([8], 13);// --></script></div><!--Menu-->
2012-05-21 20:32:26 +00:00
<!--START_ND_TOOLTIPS-->
2017-06-27 11:43:19 +00:00
<div class=CToolTip id="tt1"><div class=CClass>Base class for objects that dispatch named events. </div></div><div class=CToolTip id="tt2"><div class=CEvent>Fires when an undoable edit is dispatched. </div></div><div class=CToolTip id="tt3"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.updateLevel</td></tr></table></blockquote>Counter for the depth of nested transactions. </div></div><div class=CToolTip id="tt4"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.beginUpdate = function()</td></tr></table></blockquote>Increments the updateLevel by one. </div></div><div class=CToolTip id="tt5"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="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><div class=CToolTip id="tt6"><div class=CFunction><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td><table border=0 cellspacing=0 cellpadding=0><tr><td class="PBeforeParameters prettyprint "nowrap>function mxGraphModel(</td><td class="PParameter prettyprint " nowrap>root</td><td class="PAfterParameters prettyprint "nowrap>)</td></tr></table></td></tr></table></blockquote>Constructs a new graph model. </div></div><div class=CToolTip id="tt7"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="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><div class=CToolTip id="tt8"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.cells</td></tr></table></blockquote>Maps from Ids to cells.</div></div><div class=CToolTip id="tt9"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="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><div class=CToolTip id="tt10"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="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&rsquo;s terminals. </div></div><div class=CToolTip id="tt11"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.createIds</td></tr></table></blockquote>Specifies if the model should automatically create Ids for new cells. </div></div><div class=CToolTip id="tt12"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.prefix</td></tr></table></blockquote>Defines the prefix of new Ids. </div></div><div class=CToolTip id="tt13"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.postfix</td></tr></table></blockquote>Defines the postfix of new Ids. </div></div><div class=CToolTip id="tt14"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.nextId</td></tr></table></blockquote>Specifies the next Id to be created. </div></div><div class=CToolTip id="tt15"><div class=CVariable><blockquote><table border=0 cellspacing=0 cellpadding=0 class="Prototype"><tr><td class="prettyprint">mxGraphModel.prototype.currentEdit</td></
2012-05-21 20:32:26 +00:00
<div id=MSearchResultsWindow><iframe src="" frameborder=0 name=MSearchResults id=MSearchResults></iframe><a href="javascript:searchPanel.CloseResultsWindow()" id=MSearchResultsWindowClose>Close</a></div>
<script language=JavaScript><!--
if (browserType) {if (browserVer) {document.write("</div>"); }document.write("</div>");}// --></script></body></html>