public static void computeForEach(final ReadGraphImpl graph, int id, Types entry, final InternalProcedure<IntSet> procedure) throws DatabaseException {
- if(entry != null)
- if(entry.isReady())
- System.err.println("asd");
-
assert(procedure != null);
QueryProcessor processor = graph.processor;
@Override
public void execute(ReadGraphImpl graph, IntSet types) throws DatabaseException {
- if(entry != null) entry.addOrSet(graph, types, processor);
+ if(entry != null) {
+ entry.addOrSet(graph, types, processor);
+ entry.finish();
+ }
procedure.execute(graph, types);
}
}
});
+
+ return;
}
@Override
public void execute(ReadGraphImpl graph, int i) throws DatabaseException {
- synchronized(result) {
- result.add(i);
- }
+ result.add(i);
inc();