Examples of cloneCells()


Examples of com.mxgraph.model.mxIGraphModel.cloneCells()

   */
  public static boolean isCyclicUndirected(mxAnalysisGraph aGraph)
  {
    mxGraph graph = aGraph.getGraph();
    mxIGraphModel model = graph.getModel();
    Object[] cells = model.cloneCells(aGraph.getChildCells(graph.getDefaultParent(), true, true), true);
    mxGraphModel modelCopy = new mxGraphModel();
    mxGraph graphCopy = new mxGraph(modelCopy);
    Object parentCopy = graphCopy.getDefaultParent();
    graphCopy.addCells(cells);
    //    mxAnalysisGraph aGraphCopy = new mxAnalysisGraph(graphCopy, aGraph.getGenerator(), aGraph.getProperties());
View Full Code Here

Examples of com.mxgraph.model.mxIGraphModel.cloneCells()

   */
  public static boolean isCyclicDirected(mxAnalysisGraph aGraph)
  {
    mxGraph graph = aGraph.getGraph();
    mxIGraphModel model = graph.getModel();
    Object[] cells = model.cloneCells(aGraph.getChildCells(graph.getDefaultParent(), true, true), true);
    mxGraphModel modelCopy = new mxGraphModel();
    mxGraph graphCopy = new mxGraph(modelCopy);
    Object parentCopy = graphCopy.getDefaultParent();
    graphCopy.addCells(cells);
    mxAnalysisGraph aGraphCopy = new mxAnalysisGraph();
View Full Code Here

Examples of com.mxgraph.model.mxIGraphModel.cloneCells()

    mxGraph graph = aGraph.getGraph();
    mxIGraphModel model = graph.getModel();

    if (aGraph.getEdges(vertex, null, true, true, false, true).length >= 2)
    {
      Object[] cells = model.cloneCells(aGraph.getChildCells(graph.getDefaultParent(), true, true), true);
      mxGraphModel modelCopy = new mxGraphModel();
      mxGraph graphCopy = new mxGraph(modelCopy);
      graphCopy.addCells(cells);
      mxAnalysisGraph aGraphCopy = new mxAnalysisGraph();
      aGraphCopy.setGraph(graphCopy);
View Full Code Here

Examples of com.mxgraph.model.mxIGraphModel.cloneCells()

    int srcValue = (int) costFunction.getCost(new mxCellState(view, aGraph.getTerminal(edge, true), null));
    int destValue = (int) costFunction.getCost(new mxCellState(view, aGraph.getTerminal(edge, false), null));

    if (aGraph.getTerminal(edge, false) != null || aGraph.getTerminal(edge, true) != null)
    {
      Object[] cells = model.cloneCells(aGraph.getChildCells(graph.getDefaultParent(), true, true), true);
      mxGraphModel modelCopy = new mxGraphModel();
      mxGraph graphCopy = new mxGraph(modelCopy);
      graphCopy.addCells(cells);
      mxAnalysisGraph aGraphCopy = new mxAnalysisGraph();
      aGraphCopy.setGraph(graphCopy);
View Full Code Here

Examples of com.mxgraph.view.mxGraph.cloneCells()

    model.beginUpdate();
    try
    {
      if (isClone)
      {
        Object clone = graph.cloneCells(new Object[] { edge })[0];

        Object parent = model.getParent(edge);
        graph.addCells(new Object[] { clone }, parent);

        Object other = model.getTerminal(edge, !isSource);
View Full Code Here

Examples of com.mxgraph.view.mxGraph.cloneCells()

   *
   */
  public Object createTargetVertex(MouseEvent e, Object source)
  {
    mxGraph graph = graphComponent.getGraph();
    Object clone = graph.cloneCells(new Object[] { source })[0];
    mxIGraphModel model = graph.getModel();
    mxGeometry geo = model.getGeometry(clone);

    if (geo != null)
    {
View Full Code Here

Examples of com.mxgraph.view.mxGraph.cloneCells()

    model.beginUpdate();
    try
    {
      if (isClone)
      {
        Object clone = graph.cloneCells(new Object[] { edge })[0];

        Object parent = model.getParent(edge);
        graph.addCells(new Object[] { clone }, parent);

        Object other = model.getTerminal(edge, !isSource);
View Full Code Here

Examples of com.mxgraph.view.mxGraph.cloneCells()

   *
   */
  public Object createTargetVertex(MouseEvent e, Object source)
  {
    mxGraph graph = graphComponent.getGraph();
    Object clone = graph.cloneCells(new Object[] { source })[0];
    mxIGraphModel model = graph.getModel();
    mxGeometry geo = model.getGeometry(clone);

    if (geo != null)
    {
View Full Code Here

Examples of com.mxgraph.view.mxGraph.cloneCells()

   *
   */
  public Object createTargetVertex(MouseEvent e, Object source)
  {
    mxGraph graph = graphComponent.getGraph();
    Object clone = graph.cloneCells(new Object[] { source })[0];
    mxIGraphModel model = graph.getModel();
    mxGeometry geo = model.getGeometry(clone);

    if (geo != null)
    {
View Full Code Here

Examples of com.mxgraph.view.mxGraph.cloneCells()

    model.beginUpdate();
    try
    {
      if (isClone)
      {
        Object clone = graph.cloneCells(new Object[] { edge })[0];

        Object parent = model.getParent(edge);
        graph.addCells(new Object[] { clone }, parent);

        Object other = model.getTerminal(edge, !isSource);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.