However, if we make the assumption that CSVs should "bring their own numeric ids" (which is sort of realistic), the whole loader can be simplified a lot. Instead of passing source and target vertex types to the loader and storing them in CsvEdge objects, we can pass this information directly to the Indexer. Of course, this requires us to rework the API, e.g. introduce an addEdge(edge, sourceVertexLabel, targetVertexLabel) method, but these are easily doable.
I already reworked CSV loaders significantly in https://github.com/FTSRG/ingraph/commit/c1f07218d057373808664a8af8538875b56c4266.
However, if we make the assumption that CSVs should "bring their own numeric ids" (which is sort of realistic), the whole loader can be simplified a lot. Instead of passing source and target vertex types to the loader and storing them in
CsvEdge
objects, we can pass this information directly to theIndexer
. Of course, this requires us to rework the API, e.g. introduce anaddEdge(edge, sourceVertexLabel, targetVertexLabel)
method, but these are easily doable.