Examples of GraphElement


Examples of fbench.graph.GraphElement

        NodeList trans = element.getElementsByTagName("ECTransition");
        Vector ans = new Vector(states.getLength() + trans.getLength());
        for (int i = 0; i < states.getLength(); i++)
            ans.add(new ECState((Element) states.item(i), (i == 0)));
        for (int i = 0; i < trans.getLength(); i++) {
            GraphElement ge = GraphElement.forElement((Element) trans.item(i));
            if (ge != null)
                ans.add(ge);
        }
        return ans;
    }
View Full Code Here

Examples of fbench.graph.GraphElement

        if (n > 0) {
            nl = ((Element) nl.item(0)).getChildNodes();
            n = nl.getLength();
            for (int i = 0; i < n; i++) {
                Element el = (Element) nl.item(i);
                GraphElement ge = GraphElement.forElement(el);
                if (ge != null)
                    graph.add(ge);
            }
        }
    }
View Full Code Here

Examples of fbench.graph.GraphElement

    public Vector getGraph() {
        NodeList nl = getElement().getElementsByTagName("FB");
        int n = nl.getLength();
        Vector ans = new Vector(n * 3);
        for (int i = 0; i < n; i++) {
            GraphElement ge = GraphElement.forElement((Element) nl.item(i));
            if (ge != null)
                ans.add(ge);
        }
        addAdapters(ans, "Sockets");
        addAdapters(ans, "Plugs");
View Full Code Here

Examples of fbench.graph.GraphElement

                .getElementsByTagName(adptype);
        if (adplist.getLength() < 1)
            return;
        NodeList adps = ((Element) adplist.item(0)).getChildNodes();
        for (int i = 0; i < adps.getLength(); i++) {
            GraphElement ge = adptype.equals("Plugs") ? new Plug()
                    : new Socket();
            ge.setElement((Element) adps.item(i));
            if (ge != null)
                graph.add(ge);
        }
    }
View Full Code Here

Examples of fbench.graph.GraphElement

     */
    public Vector getGraph() {
        NodeList nl = getElement().getChildNodes();
        Vector ans = new Vector(nl.getLength());
        for (int i = 0; i < nl.getLength(); i++) {
            GraphElement ge = GraphElement.forElement((Element) nl.item(i));
            if (ge != null)
                ans.add(ge);
        }
        return ans;
    }
View Full Code Here

Examples of fbench.graph.GraphElement

  }

  protected void addResources(Vector graph, Element el) {
    NodeList nl = el.getElementsByTagName("Resource");
    for (int i = 0; i < nl.getLength(); i++) {
      GraphElement ge = GraphElement.forElement((Element) nl.item(i));
      if (ge != null)
        graph.addElement(ge);
    }

  }
View Full Code Here

Examples of fbench.graph.GraphElement

      connectionType = "InputVars";
    else if(!isEvent&& !isInput)
      connectionType = "OutputVars";

    for ( Enumeration els = model.getGraph().elements(); els.hasMoreElements();) {
      GraphElement ge = (GraphElement) els.nextElement();
      if(ge instanceof FB){
        FB fb = (FB)ge;
        if(fb.getMainLabel().getText().equals(fbName)){
          Document fbDocument = Library.getDocument(fb.getFBType() + ".fbt");
          if(fbDocument != null){
View Full Code Here

Examples of fbench.graph.GraphElement

    fbPreviewPane.removeAll();
    GraphModel model = GraphModel.forElement(docElement);
    if (model != null) {
      for ( Enumeration els = model.getGraph().elements(); els.hasMoreElements();) {
        GraphElement ge = (GraphElement) els.nextElement();
        fbPreviewPane.add(ge);
      }
    }
    Dimension fbPaneSize =
      fbPreviewPane.getLayout().preferredLayoutSize(fbPreviewPane);
View Full Code Here

Examples of fbench.graph.GraphElement

      String destinationFBName = destinationFBBox.getSelectedItem().toString();
      int connectionStartPt = 0;
      int connectionEndPt = 0;
      GraphModel model = GraphModel.forElement(getElement());
      for ( Enumeration els = model.getGraph().elements(); els.hasMoreElements();) {
        GraphElement ge = (GraphElement) els.nextElement();
        if(ge instanceof FB){
          FB fb = (FB)ge;
          if(fb.getMainLabel().getText().equals(sourceFBName))
            connectionStartPt = fb.getPreferredBounds().x;
          else if(fb.getMainLabel().getText().equals(destinationFBName))
View Full Code Here

Examples of org.aperteworkflow.bpm.graph.GraphElement

                loger.fine("Handling: " + hpi.getActivityName());
                if (hpi instanceof HistoryActivityInstanceImpl) {
                    HistoryActivityInstanceImpl activity = (HistoryActivityInstanceImpl) hpi;
                    String activityName = activity.getActivityName();
                    if (res.isEmpty()) { //initialize start node and its transition
                        GraphElement startNode = processGraphElements.get("__AWF__start_node");
                        if (startNode != null) {
                            res.add(startNode);
                        }
                        GraphElement firstTransition = processGraphElements.get("__AWF__start_transition_to_" + activityName);
                        if (firstTransition != null) {
                            res.add(firstTransition);
                        }
                    }
                  
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.