+ @Override
+ public List<Edge> findEdgesForVersion(Vertex start, Loader loader) {
+ // From the given start vertex find both the
+ // out edges that has property CONTAINS set to NONE
+ // whose in vertexes has an object that is declared in the oxm
+ // And do the same thing vice versa to get a list of edges
+ // Then check that the edge should not have the property private set to true
+ // and remove the duplicates and return the list of edges
+ final Set<String> objects = loader.getAllObjects().keySet();
+ GraphTraversal<Vertex, Edge> pipeline = this.g.V(start)
+ .union(__.inE().has(CONTAINS.toString(), NONE.toString())
+ .where(__.outV().has(AAIProperties.NODE_TYPE, P.within(objects))),
+ __.outE().has(CONTAINS.toString(), NONE.toString())
+ .where(__.inV().has(AAIProperties.NODE_TYPE, P.within(objects))))
+ .not(__.has("private", true)).dedup();
+
+ return pipeline.toList();
+ }