繁体   English   中英

在java中的gremlin titan中过滤出顶点数量上的顶点

[英]filter vertices on number of outgoing edges in gremlin titan in java

我想使用java中的gremlin查询和过滤titan中具有超过500个向外边缘的所有顶点...我该怎么做?我已经开始如下

    pipe=pipe.start(graph.getVertices());

然后,您需要一个过滤器功能

p.start(
  g.getVertices()
   .filter(new PipeFunction<Vertex,Boolean>() {    
             public Boolean compute(Vertex v) {
               // write your logic here to count edges on the vertex and 
               // return true if over 500 and false otherwise
             }));

此处详细介绍在Java中使用GremlinPipeline

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM