Skip to content

Commit

Permalink
[dbs-leipzig#1200] unified graph head handling
Browse files Browse the repository at this point in the history
  • Loading branch information
galpha committed Apr 12, 2019
1 parent 06d2709 commit 6ae9503
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 8 deletions.
Expand Up @@ -142,8 +142,7 @@ public LogicalGraph sample(LogicalGraph graph) {
.where(new TargetId<>()).equalTo(new Id<>())
.with(new LeftSide<>());

graph = graph.getConfig().getLogicalGraphFactory().fromDataSets(
graph.getGraphHead(), scaledVertices, newEdges);
graph = graph.getConfig().getLogicalGraphFactory().fromDataSets(scaledVertices, newEdges);

return graph;
}
Expand Down
Expand Up @@ -79,6 +79,7 @@ public LogicalGraph sample(LogicalGraph graph) {
.distinct(new Id<>());

DataSet<Vertex> newVertices = newSourceVertices.union(newTargetVertices).distinct(new Id<>());
return graph.getConfig().getLogicalGraphFactory().fromDataSets(newVertices, newEdges);

return graph.getFactory().fromDataSets(newVertices, newEdges);
}
}
Expand Up @@ -136,8 +136,7 @@ public LogicalGraph sample(LogicalGraph graph) {
.where(new TargetId<>()).equalTo(new Id<>())
.with(new LeftSide<>());

return graph.getConfig().getLogicalGraphFactory()
.fromDataSets(graph.getGraphHead(), newVertices, newEdges);
return graph.getFactory().fromDataSets(newVertices, newEdges);
}

}
Expand Up @@ -107,7 +107,6 @@ public LogicalGraph sample(LogicalGraph graph) {
.where(new TargetId<>()).equalTo(new Id<>())
.with(new LeftSide<>());

return graph.getConfig().getLogicalGraphFactory()
.fromDataSets(graph.getGraphHead(), newVertices, newEdges);
return graph.getFactory().fromDataSets(newVertices, newEdges);
}
}
Expand Up @@ -76,6 +76,6 @@ public LogicalGraph sample(LogicalGraph graph) {
.where(new TargetId<>()).equalTo(new Id<>())
.with(new LeftSide<>());

return graph.getConfig().getLogicalGraphFactory().fromDataSets(newVertices, newEdges);
return graph.getFactory().fromDataSets(newVertices, newEdges);
}
}

0 comments on commit 6ae9503

Please sign in to comment.