我刚刚遇到BluePrints API的问题。 我执行了以下Scala命令:
val dbBasename = "C:\\Users\\taatoal1\\tmp\\orientdb\\databases\\"
val dbpath = "test_ingest"
val (uname, pwd) = ("admin", "admin")
val graph = new OrientGraph(s"plocal:$dbpath", uname, pwd)
graph.addVertex("class:Employee")
我收到以下错误
<console>:14: error: ambiguous reference to overloaded definition,
both method addVertex in class OrientBaseGraph of type (x$1: Any, x$2: <repeated...>[Object])com.tinkerpop.blueprints.impls.orient.OrientVertex
and method addVertex in class OrientBaseGraph of type (x$1: Any)com.tinkerpop.blueprints.impls.orient.OrientVertex
match argument types (String)
graph.addVertex("class:Employee")
^
你知道我做错了吗?
提前致谢
答案 0 :(得分:1)
最后我发现还有另一个addVertex
版本,它接受两个字符串作为参数:类名和集群名。