Package edu.uci.ics.jung.graph.impl

Examples of edu.uci.ics.jung.graph.impl.DirectedSparseGraph.addUserDatum()


                            {
                              Configuration config = Configuration.getDefaultConfiguration().copy();
                              LearnerGraphND machine = new LearnerGraphND(config);Synapse.StatechumProcess.parseStatemachine(message.elementAt(2),machine,null,true);
                              DirectedSparseGraph fsmPicture = machine.pathroutines.getGraph();
                              if (!fsmPicture.containsUserDatumKey(JUConstants.LAYOUTOPTIONS))
                                fsmPicture.addUserDatum(JUConstants.LAYOUTOPTIONS,new LayoutOptions(), UserData.SHARED);
                              int windowNumber = setOptions(message,3,fsmPicture);
                              if (windowNumber >= 0)
                                Visualiser.updateFrameWithPos(fsmPicture,windowNumber);

                              outcome = new OtpErlangTuple(new OtpErlangObject[]{ref,msgOk});
View Full Code Here


    Map<String,String> labelling = new TreeMap<String,String>();
    for(Entry<VertexID,VertexID> entry:oldVerticesToNew.entrySet())
      labelling.put(entry.getKey().toString(),entry.getValue().toString());
    DirectedSparseGraph gr = outcome.pathroutines.getGraph();
   
    gr.addUserDatum(JUConstants.VERTEX, labelling, UserData.SHARED);
    gr.addUserDatum(JUConstants.EDGE, transitionAnnotation, UserData.SHARED);
    return gr;
  }
 
View Full Code Here

    for(Entry<VertexID,VertexID> entry:oldVerticesToNew.entrySet())
      labelling.put(entry.getKey().toString(),entry.getValue().toString());
    DirectedSparseGraph gr = outcome.pathroutines.getGraph();
   
    gr.addUserDatum(JUConstants.VERTEX, labelling, UserData.SHARED);
    gr.addUserDatum(JUConstants.EDGE, transitionAnnotation, UserData.SHARED);
    return gr;
  }
 
View Full Code Here

    Map<String,String> labelling = new TreeMap<String,String>();
    for(Entry<VertexID,VertexID> entry:oldVerticesToNew.entrySet())
      labelling.put(entry.getKey().toString(),entry.getValue().toString());
    DirectedSparseGraph gr = outcome.pathroutines.getGraph();
   
    gr.addUserDatum(JUConstants.VERTEX, labelling, UserData.SHARED);
    gr.addUserDatum(JUConstants.EDGE, transitionAnnotation, UserData.SHARED);
    return gr;
  }
 
View Full Code Here

    for(Entry<VertexID,VertexID> entry:oldVerticesToNew.entrySet())
      labelling.put(entry.getKey().toString(),entry.getValue().toString());
    DirectedSparseGraph gr = outcome.pathroutines.getGraph();
   
    gr.addUserDatum(JUConstants.VERTEX, labelling, UserData.SHARED);
    gr.addUserDatum(JUConstants.EDGE, transitionAnnotation, UserData.SHARED);
    return gr;
  }
 
View Full Code Here

      public void pairCompatibility(String stateA, PAIRCOMPATIBILITY pairRelation, String stateB) {
        PairCompatibility<Vertex> pairCompatibility = (PairCompatibility<Vertex>)g.getUserDatum(JUConstants.PAIR_COMPATIBILITY);
        if (pairCompatibility == null)
        {
          pairCompatibility = new PairCompatibility<Vertex>(config.getMaxStateNumber());
          g.addUserDatum(JUConstants.PAIR_COMPATIBILITY, pairCompatibility, UserData.SHARED);
        }
        if (!existingVertices.containsKey(stateA))
          throw new IllegalArgumentException("unknown vertex "+stateA);
        if (!existingVertices.containsKey(stateB))
          throw new IllegalArgumentException("unknown vertex "+stateB);
View Full Code Here

      vertexExtraLabel.put(vert.toString(), "\n"+counter+" seq");
    }
    //System.out.println(transitionsUsedInC+"\n###################\n"+vertexExtraLabel);
   
    DirectedSparseGraph gr = graph.pathroutines.getGraph();
    gr.addUserDatum(JUConstants.VERTEX, vertexExtraLabel, UserData.CLONE);
    gr.addUserDatum(JUConstants.EDGE, transitionsUsedInC, UserData.CLONE);
   
    GD gd = new GD();
    int counter = 0;
View Full Code Here

    }
    //System.out.println(transitionsUsedInC+"\n###################\n"+vertexExtraLabel);
   
    DirectedSparseGraph gr = graph.pathroutines.getGraph();
    gr.addUserDatum(JUConstants.VERTEX, vertexExtraLabel, UserData.CLONE);
    gr.addUserDatum(JUConstants.EDGE, transitionsUsedInC, UserData.CLONE);
   
    GD gd = new GD();
    int counter = 0;

    DirectedSparseGraph aGraph = gd.showGD(
View Full Code Here

                            {
                              Configuration config = Configuration.getDefaultConfiguration().copy();
                              LearnerGraphND machine = new LearnerGraphND(config);Synapse.StatechumProcess.parseStatemachine(message.elementAt(2),machine,null,true);
                              DirectedSparseGraph fsmPicture = machine.pathroutines.getGraph();
                              if (!fsmPicture.containsUserDatumKey(JUConstants.LAYOUTOPTIONS))
                                fsmPicture.addUserDatum(JUConstants.LAYOUTOPTIONS,new LayoutOptions(), UserData.SHARED);
                              int windowNumber = setOptions(message,3,fsmPicture);
                              if (windowNumber >= 0)
                                Visualiser.updateFrameWithPos(fsmPicture,windowNumber);

                              outcome = new OtpErlangTuple(new OtpErlangObject[]{ref,msgOk});
View Full Code Here

      updateAnnotationsWithColour(outcome, added, transitionAnnotation, Color.GREEN);
      updateAnnotationsWithColour(outcome, removed, transitionAnnotation, Color.RED);
      DeterministicDirectedSparseGraph.findInitial(outcome).removeUserDatum(JUConstants.INITIAL);
      DeterministicDirectedSparseGraph.findVertexNamed(added.getInit(),outcome).addUserDatum(JUConstants.INITIAL, true, UserData.SHARED);
      Visualiser.LayoutOptions options = new Visualiser.LayoutOptions();options.showDIFF=true;
      outcome.addUserDatum(JUConstants.LAYOUTOPTIONS,options, UserData.SHARED);
      return outcome;
    }


  }
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.