如果有多个边连接同一对节点,both
将返回重复节点:
gremlin> v2 = g.addVertex(null,['x':5,'y':7])
==>v[360004]
gremlin> v3 = g.addVertex(null, ['x':2,'y':3])
==>v[360008]
gremlin> g.addEdge(v2,v3,'test')
==>e[6IeZ-1vEw-2F0LaTPQQu][360004-test->360008]
gremlin> g.addEdge(v2,v3,'test 2')
==>e[6If7-1vEw-2F0LaTPQQC][360004-test 2->360008]
gremlin> v2.both.map
==>{y=3, x=2}
==>{y=3, x=2}
如何确保我得到一个不同的节点列表?