} catch (final InterruptedException e) {
log.error(e.getMessage(), e);
}
final Date intermediate = new Date();
final TimeInterval codemapInterval = new TimeInterval(start, intermediate);
log.info("Codemap constructed in: {}", codemapInterval);
log.info("Codemap contains {} entries!", LazyLiteral.getHm().size());
// for debugging purposes:
// final TripleConsumer interTripleConsumer = new TripleConsumer() {
// public void consume(final Triple triple) {
//
// // the generated codes using the dictionary:
// System.out.println("(" + getCode(triple.getSubject())
// + ", " + getCode(triple.getPredicate()) + ", "
// + getCode(triple.getObject()) + ")");
//
// indices.consume(triple);
// }
//
// };
//
// new GenerateIDTriplesUsingStringSearch2(rdfURL, dataFormat,
// interTripleConsumer);
final Indices indices = new SixIndices(defaultGraphs.iterator().next());
new GenerateIDTriplesUsingStringSearch2(defaultGraphs, dataFormat, indices);
// write out index info
final OutputStream out = new BufferedOutputStream(new FileOutputStream(writeindexinfo));
indices.constructCompletely();
OutHelper.writeLuposInt(lupos.datastructures.paged_dbbptree.DBBPTree.getCurrentFileID(), out);
((lupos.datastructures.paged_dbbptree.DBBPTree) ((StringIntegerMapJava) LazyLiteral.getHm()).getOriginalMap()).writeLuposObject(out);
((StringArray) LazyLiteral.getV()).writeLuposStringArray(out);
OutHelper.writeLuposInt(1, out);
LiteralFactory.writeLuposLiteral(defaultGraphs.iterator().next(), out);
indices.writeIndexInfo(out);
OutHelper.writeLuposInt(0, out);
out.close();
final Date end = new Date();
log.debug("_______________________________________________________________");
log.info("Done, RDF3X index constructed!");
log.debug("End time: {}", end);
log.debug("Used time: {}", new TimeInterval(start, end));
log.debug("Number of imported triples: {}", ((SixIndices)indices).getIndex(CollationOrder.SPO).size());
} catch (final Exception e) {
log.error(e.getMessage(), e);
}
}