使用 Neo4j 2.0 里程碑 3
目前有这个代码(工作代码)
String DB_PATH = "/usr/local/Cellar/neo4j/community-1.8.1-unix/libexec/data/graph.db";
GraphDatabaseService graphDb = new GraphDatabaseFactory().newEmbeddedDatabase(DB_PATH);
Transaction tx = graphDb.beginTx();
try {
Node myNode = graphDb.createNode();
tx.success();
}
finally {
tx.finish();
}
这是嵌入式 API。如何向我的节点添加标签?谢谢!