GDF file reader that can write data from a GDF stream to TinkerPop 2.x graph
GDFpop provides GDFReader that takes care of parsing the GDF file stream and populating TinkerPop 2.x Graph that is provided as an input. For more details, please take a look at the GDFReaderTest. For example-
// initialize TinkerPop Graph
Graph graph = new TinkerGraph();
// read in the GDF stream
GDFReader.inputGraph(graph, GDFReader.class.getResourceAsStream("graph-example.gdf"), "'", null);
// use blueprints as usual
Vertex a = graph.getVertex("a");
There are three optional parameters-
- buf: Takes in a buffer size for BatchGraph. See BatchGraph for more details.
- quote: You can specify the quote character that is being used for the values. Default is double quotes.
- eidp: Edge property to be used as an ID