Package | Description |
---|---|
com.mxgraph.model |
This package contains the classes that define a graph model.
|
com.mxgraph.util |
This package provides utility classes such as mxConstants, mxUtils, mxPoint
and mxRectangle as well as all classes for custom events and the undo
history.
|
com.mxgraph.view |
This package implements the graph component, represented by the mxGraph
class.
|
Modifier and Type | Class and Description |
---|---|
class |
mxGraphModel
Extends mxEventSource to implement a graph model.
|
Modifier and Type | Field and Description |
---|---|
protected mxIGraphModel |
mxIGraphModel.mxAtomicGraphModelChange.model
Holds the model where the change happened.
|
Modifier and Type | Method and Description |
---|---|
mxIGraphModel |
mxIGraphModel.mxAtomicGraphModelChange.getModel()
Returns the model where the change happened.
|
Modifier and Type | Method and Description |
---|---|
static java.util.Collection<java.lang.Object> |
mxGraphModel.filterDescendants(mxIGraphModel model,
mxGraphModel.Filter filter)
Creates a collection of cells using the visitor pattern.
|
static java.util.Collection<java.lang.Object> |
mxGraphModel.filterDescendants(mxIGraphModel model,
mxGraphModel.Filter filter,
java.lang.Object parent)
Creates a collection of cells using the visitor pattern.
|
static java.lang.Object[] |
mxGraphModel.getChildCells(mxIGraphModel model,
java.lang.Object parent,
boolean vertices,
boolean edges)
Returns the children of the given cell that are vertices and/or edges
depending on the arguments.
|
static java.lang.Object[] |
mxGraphModel.getChildEdges(mxIGraphModel model,
java.lang.Object parent)
Returns the child edges of the given parent.
|
static java.lang.Object[] |
mxGraphModel.getChildren(mxIGraphModel model,
java.lang.Object parent)
Returns all children of the given cell regardless of their type.
|
static java.lang.Object[] |
mxGraphModel.getChildVertices(mxIGraphModel model,
java.lang.Object parent)
Returns the child vertices of the given parent.
|
static java.lang.Object[] |
mxGraphModel.getConnections(mxIGraphModel model,
java.lang.Object cell)
Returns all edges connected to this cell without loops.
|
static java.util.Collection<java.lang.Object> |
mxGraphModel.getDescendants(mxIGraphModel model,
java.lang.Object parent)
Returns a all descendants of the given cell and the cell itself
as a collection.
|
static int |
mxGraphModel.getDirectedEdgeCount(mxIGraphModel model,
java.lang.Object cell,
boolean outgoing)
Returns the number of incoming or outgoing edges.
|
static int |
mxGraphModel.getDirectedEdgeCount(mxIGraphModel model,
java.lang.Object cell,
boolean outgoing,
java.lang.Object ignoredEdge)
Returns the number of incoming or outgoing edges, ignoring the given
edge.
|
static java.lang.Object[] |
mxGraphModel.getEdges(mxIGraphModel model,
java.lang.Object cell)
Returns all edges connected to this cell including loops.
|
static java.lang.Object[] |
mxGraphModel.getEdges(mxIGraphModel model,
java.lang.Object cell,
boolean incoming,
boolean outgoing,
boolean includeLoops)
Returns all distinct edges connected to this cell.
|
static java.lang.Object[] |
mxGraphModel.getEdgesBetween(mxIGraphModel model,
java.lang.Object source,
java.lang.Object target)
Returns all edges from the given source to the given target.
|
static java.lang.Object[] |
mxGraphModel.getEdgesBetween(mxIGraphModel model,
java.lang.Object source,
java.lang.Object target,
boolean directed)
Returns all edges between the given source and target pair.
|
static java.lang.Object[] |
mxGraphModel.getIncomingEdges(mxIGraphModel model,
java.lang.Object cell)
Returns the incoming edges of the given cell without loops.
|
static java.lang.Object[] |
mxGraphModel.getOpposites(mxIGraphModel model,
java.lang.Object[] edges,
java.lang.Object terminal)
Returns all opposite cells of terminal for the given edges.
|
static java.lang.Object[] |
mxGraphModel.getOpposites(mxIGraphModel model,
java.lang.Object[] edges,
java.lang.Object terminal,
boolean sources,
boolean targets)
Returns all opposite vertices wrt terminal for the given edges, only
returning sources and/or targets as specified.
|
static java.lang.Object[] |
mxGraphModel.getOutgoingEdges(mxIGraphModel model,
java.lang.Object cell)
Returns the outgoing edges of the given cell without loops.
|
static java.lang.Object[] |
mxGraphModel.getParents(mxIGraphModel model,
java.lang.Object[] cells) |
static java.lang.Object[] |
mxGraphModel.getTopmostCells(mxIGraphModel model,
java.lang.Object[] cells)
Function: getTopmostCells
Returns the topmost cells of the hierarchy in an array that contains no
desceandants for each
|
void |
mxIGraphModel.mxAtomicGraphModelChange.setModel(mxIGraphModel model)
Sets the model where the change is to be carried out.
|
static void |
mxGraphModel.setTerminals(mxIGraphModel model,
java.lang.Object edge,
java.lang.Object source,
java.lang.Object target)
Sets the source and target of the given edge in a single atomic change.
|
Constructor and Description |
---|
mxAtomicGraphModelChange(mxIGraphModel model)
Constructs an atomic graph model change for the given model.
|
Modifier and Type | Method and Description |
---|---|
static void |
mxUtils.setCellStyleFlags(mxIGraphModel model,
java.lang.Object[] cells,
java.lang.String key,
int flag,
java.lang.Boolean value)
Deprecated.
Use
mxStyleUtils.setCellStyleFlags(mxIGraphModel, Object[],String, int, Boolean) (Jan 2012) |
static void |
mxStyleUtils.setCellStyleFlags(mxIGraphModel model,
java.lang.Object[] cells,
java.lang.String key,
int flag,
java.lang.Boolean value)
Sets or toggles the flag bit for the given key in the cell's styles.
|
static void |
mxUtils.setCellStyles(mxIGraphModel model,
java.lang.Object[] cells,
java.lang.String key,
java.lang.String value)
Deprecated.
Use
mxStyleUtils.setCellStyles(mxIGraphModel, Object[], String, String) (Jan 2012) |
static void |
mxStyleUtils.setCellStyles(mxIGraphModel model,
java.lang.Object[] cells,
java.lang.String key,
java.lang.String value)
Assigns the value for the given key in the styles of the given cells, or
removes the key from the styles if the value is null.
|
Modifier and Type | Field and Description |
---|---|
protected mxIGraphModel |
mxGraph.model
Holds the model that contains the cells to be displayed.
|
Modifier and Type | Method and Description |
---|---|
mxIGraphModel |
mxGraph.getModel()
Returns the graph model that contains the graph data.
|
Modifier and Type | Method and Description |
---|---|
mxRectangle |
mxGraph.graphModelChanged(mxIGraphModel sender,
java.util.List<mxUndoableEdit.mxUndoableChange> changes)
Called when the graph model changes.
|
void |
mxGraph.setModel(mxIGraphModel value)
Sets the graph model that contains the data, and fires an
mxEvent.CHANGE followed by an mxEvent.REPAINT event.
|
Constructor and Description |
---|
mxGraph(mxIGraphModel model)
Constructs a new graph for the specified model.
|
mxGraph(mxIGraphModel model,
mxStylesheet stylesheet)
Constructs a new graph for the specified model.
|
Copyright (c) 2010-2017 Gaudenz Alder, JGraph Ltd. All rights reserved.