Examples of Node


Examples of umat.beans.Node

public class NewClass {
    public static void main(String[] args){
        Tree tree=new Tree();
       XMLController ctr=new XMLController(tree);
       tree.getRoot().setData("NewTree");
       Node n1=new Node("n1",tree.getRoot());
       Node n2=new Node("n2",tree.getRoot());
       Node n3=new Node("n3",tree.getRoot());
      
       n1.setFieldName("f1");
       n1.setFieldType("String");
       n1.addField();
      
       n2.setFieldName("f2");
       n2.setFieldType("String");
       n2.addField();
      
       Node n21=new Node("n2.1",n2);
       Node n22=new Node("n2.2",n2);
      
       Node n31=new Node("n3.1",n3);
       n31.setFieldName("f31");
       n31.setFieldType("String");
       n31.addField();
       Node n32=new Node("n3.2",n3);

       ctr.parseToXML();
      
      
       String xml = "<?xml version=\"1.0\"?><!DOCTYPE cael []>"+

Examples of unbbayes.prs.Node

      } else {
        nos = net.getDescriptionNodes();
      }
      int size = nos.size();
      for (int i = 0; i < size; i++) {
        Node node = (Node) nos.get(i);
        DefaultMutableTreeNode treeNode = findUserObject(node
            .getDescription(), root);
        if (treeNode != null) {
          objectsMap.put(treeNode, node);
        } else {
          DefaultMutableTreeNode newNode = new DefaultMutableTreeNode(
              node.getDescription());
          objectsMap.put(newNode, node);
          root.add(newNode);
        }
      }
      ((DefaultTreeModel) getModel()).reload(root);

Examples of urban.shapes.Node

     
      int i=1;
      while(!q.isEmpty()){
        RuleGraph graph = q.poll();
       
        Node root = graph.getRoot();
        if (root instanceof BondNode){
          Iterator<Entry<Link, RuleGraph>> children = sorted(graph.getChildren()).iterator();
          Entry<Link, RuleGraph> entry1 = children.next();
          Entry<Link, RuleGraph> entry2 = children.next();
         
          Node a = entry1.getValue().getRoot();
          Node b = entry2.getValue().getRoot();
          get(rhs,a).add(new Site(a.getName(), entry1.getKey().getDst(), null, ""+i));
          get(rhs,b).add(new Site(b.getName(), entry2.getKey().getDst(), null, ""+i));
          i++;
          q.add(entry1.getValue());
          q.add(entry2.getValue());
        } else {
          ordering.add(root);
          String agent = root.getName();
          List<Site> sitesL = get(lhs, root);
          List<Site> sitesR = get(rhs, root);
          addAll(sitesL, root.getSitesL());
          addAll(sitesR, root.getSitesR());
          for(Entry<Link, RuleGraph> e : sorted(graph.getChildren())){
            if (e.getValue() == null){
              String siteName = e.getKey().getSrc();
              sitesL.add(new Site(agent, siteName, null, "_"));
              sitesR.add(new Site(agent, siteName, null, "_"));         
            } else {
              if (!lhs.containsKey(e.getValue().getRoot())){
                q.add(e.getValue());
              }
              String src = e.getKey().getSrc();
              sitesL.add(new Site(agent, src, null, ""+i));
              sitesR.add(new Site(agent, src, null, ""+i));
              Node root2 = e.getValue().getRoot();
              String dst = e.getKey().getDst();
              get(lhs, root2).add(new Site(root2.getName(), dst, null, ""+i));
              get(rhs, root2).add(new Site(root2.getName(), dst, null, ""+i));       
              i++;
            }
          }
        }
      }

Examples of util.ui.view.Node

    skinPanel.add(centerPanel, BorderLayout.CENTER);

    mChannelChooser = new ChannelChooserPanel(this);

    /* create structure */
    mRootNode = new Node(null);

    if(Settings.propPluginViewIsLeft.getBoolean()) {
      mPluginsNode = new Node(mRootNode);
    }
    else {
      mNavigationNode = new Node(mRootNode);
    }

    mMainframeNode = new Node(mRootNode);
    Node programtableNode = new Node(mMainframeNode);

    if(Settings.propPluginViewIsLeft.getBoolean()) {
      mNavigationNode = new Node(mMainframeNode);
    }
    else {
      mPluginsNode = new Node(mMainframeNode);
    }

    mTimebuttonsNode = new Node(mNavigationNode);
    mDateChannelNode = new Node(mNavigationNode);
    mDateNode = new Node(mDateChannelNode);
    mChannelNode = new Node(mDateChannelNode);

    mRootNode.setProperty(Settings.propViewRoot);
    mMainframeNode.setProperty(Settings.propViewMainframe);
    mNavigationNode.setProperty(Settings.propViewNavigation);
    mDateChannelNode.setProperty(Settings.propViewDateChannel);

    /* create views */
    programtableNode.setLeaf(skinPanel);
    this.setShowPluginOverview(Settings.propShowPluginView.getBoolean());
    this.setShowTimeButtons(Settings.propShowTimeButtons.getBoolean());
    this.setShowDatelist(Settings.propShowDatelist.getBoolean());
    this.setShowChannellist(Settings.propShowChannels.getBoolean());

Examples of vn.pyco.tinycms.model.Node

        if (path == null || path.isEmpty()) {
            return null;
        }
       
        // get directly page by path
        Node node = _nodeDao.getByPath(path, Node.class);
        if (!(node instanceof Page)) {
            // the path is site or section, get default page of it
            node = _nodeDao.getDefaultPage(path);
            if (node == null) {
                // no default page, get the first page

Examples of voldemort.cluster.Node

        List<Node> nodes = new ArrayList<Node>();
        for(int i = 0; i < numNodes * tagsPerNode; i++)
            tags.add(i);

        for(int i = 0; i < numNodes; i++)
            nodes.add(new Node(i, "host", 8080, 6666, 6667, tags.subList(tagsPerNode * i,
                                                                         tagsPerNode * (i + 1))));

        // use a seed so that this test is repeatable
        Random random = new Random(2158745224L);
        Collections.shuffle(nodes, random);

Examples of weka.gui.treevisualizer.Node

    //
    resourceSet.getPackageRegistry().put(_40Package.eNS_URI,
        _40Package.eINSTANCE);

    TreeBuild builder = new TreeBuild();     
    Node nodeOfWeka = builder.create(new StringReader(dott));

    Resource resource = resourceSet.createResource(URI.createURI("http://www.admire-project.eu/PMML-4_0"));
   
    DocumentRoot documentRoot = _40Factory.eINSTANCE.createDocumentRoot();
   

Examples of xmlstreamparser.Node

   * get the jid info found
   * @param node
   * @return the jid
   */
  public static String getJidfromResponse(Node node) {
    Node query = node.getChild("query");
    StringBuffer result = new StringBuffer();
    Vector items = query.getChildren();
    for (int i=0;i<items.size();i++) {
      Node n = (Node)items.elementAt(i);
      if (n.name.equals("item")) { //PATCH 2008
        if (n.getValue("jid") != null)
          result.append("jid: ").append(n.getValue("jid")).append("\n");
        if (n.getChild("name") != null)
          result.append("username: ").append(n.getChild("name").text).append("\n");
        if (n.getChild("first") != null)
          result.append("name: ").append(n.getChild("first").text).append("\n");
        if (n.getChild("last") != null)
          result.append("surname: ").append(n.getChild("last").text).append("\n");
        if (n.getChild("nick") != null)
          result.append("nick: ").append(n.getChild("nick").text).append("\n");
        if (n.getChild("email") != null)
          result.append("mail: ").append(n.getChild("email").text).append("\n").append("\n");
       
      }
    }
        if (result.toString().equals(""))
            return Contents.jud_nores;

Examples of xtc.tree.Node

   * @throws IOException Signals an I/O error.
   */
  private Result pInfixPatternTail(final int yyStart) throws IOException {
    Result     yyResult;
    int        yyOption1;
    Node       yyValue;
    ParseError yyError = ParseError.DUMMY;

    // Alternative 1.

    yyResult = pId(yyStart);
    yyError  = yyResult.select(yyError);
    if (yyResult.hasValue()) {
      Node v$g$1 = yyResult.semanticValue();

      yyOption1  = yyResult.index;

      yyResult = pN(yyOption1);
      yyError  = yyResult.select(yyError, yyOption1);
      if (yyResult.hasValue()) {

        yyOption1  = yyResult.index;
      }

      yyResult = pSimplePattern(yyOption1);
      yyError  = yyResult.select(yyError);
      if (yyResult.hasValue()) {
        Node v$g$2 = yyResult.semanticValue();

        yyValue = GNode.create("InfixPatternTail", v$g$1, v$g$2);
        yyValue.setLocation(location(yyStart));

        return yyResult.createValue(yyValue, yyError);

Examples of y.base.Node

        Assert.assertTrue("Command should add entities", command.getEditedEntities().size() > 0);
        Assert.assertTrue("Command should add associations", command.getEditedAssociations().size() > 0);
        Assert.assertTrue("Command should add class " + galaxyClass, command.getEditedEntities().contains(galaxyClass));
        Assert.assertTrue("Command should add method " + galaxyContstructor, command.getEditedEntities().contains(galaxyContstructor));

        Node planetClassNode = graph.getNode(planetClass);
        Node galaxyClassNode = graph.getNode(galaxyClass);
        Node galaxyConstructorNode = graph.getNode(galaxyContstructor);
        Assert.assertEquals("Parent node of " + galaxyConstructorNode + " has to be " + galaxyClassNode, galaxyClassNode, graph.getHierarchyManager().getParentNode(galaxyConstructorNode));

        Edge invocation = galaxyClassNode.getEdge(planetClassNode);
        Assert.assertNotNull("There should be an edge between " + galaxyClassNode + " and " + planetClassNode, invocation);
    }
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.