Package org.structr.core.graph

Examples of org.structr.core.graph.NodeAttribute


     
      TestEight test = null;
     
      try (final Tx tx = app.tx()) {

        test = app.create(TestEight.class, new NodeAttribute(TestEight.testProperty, 123));
        tx.success();
      }
     
      // only the creation methods should have been called now!
      assertTrue("onCreationTimestamp should be != 0", test.getOnCreationTimestamp() != 0L);
View Full Code Here


  }

  // ----- public methods -----
  @Override
  public <T extends NodeInterface> T create(final Class<T> type, final String name) throws FrameworkException {
    return create(type, new NodeAttribute(AbstractNode.name, name));
  }
View Full Code Here

    final List<NodeAttribute<?>> attrs = new LinkedList<>(Arrays.asList(attributes));
    final CreateNodeCommand<T> command = command(CreateNodeCommand.class);

    // add type information when creating a node
    attrs.add(new NodeAttribute(AbstractNode.type, type.getSimpleName()));

    return command.execute(attrs);
  }
View Full Code Here

TOP

Related Classes of org.structr.core.graph.NodeAttribute

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.