Package fbench.graph

Examples of fbench.graph.Event


  protected void addInterfaceElements(Element intfcs, String tag,
      Vector graph, boolean isInputs, boolean isEvents, int x0) {
    NodeList lst = intfcs.getElementsByTagName(tag);
    if (lst.getLength() < 1)
      return;
    Event evt = null;
    NodeList evts = lst.item(0).getChildNodes();
    int n = evts.getLength();
    if (isEvents)
      gap = 10 * n + 10;
    if (!isInputs)
      x0 += gap;
    for (int i = 0; i < n; i++) {
      evt = (Event) GraphElement.forElement((Element) evts.item(i));
      evt.setPreferredLocation(x0, y);
      graph.add(evt);
      y += dy;
      if (isInputs)
        fbx = Math.max(fbx, evt.getPreferredSize().width + gap);
      IOLink lnk = isInputs ? new IOLink(evt, fbt, isEvents)
          : new IOLink(fbt, evt, isEvents);
      lnk.setElement(evt.getElement());
      graph.add(lnk);
      if (isEvents)
        graph.add(new WithLink(lnk, fbt));
    }
  }
View Full Code Here

TOP

Related Classes of fbench.graph.Event

Copyright © 2018 www.massapicom. 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.