Class OsmCsvGraphLoader

java.lang.Object
org.jgrapht.osm.OsmCsvGraphLoader

public final class OsmCsvGraphLoader extends Object
Loads a headerless weighted edge-list CSV (the format produced by GpkgRoadGraphPreprocessor) into a target Graph. The actual parsing is delegated to CSVImporter from jgrapht-io; this class only adds gzip support and the conventional Integer-vertex factory.

CSV schema (one directed edge per line, no header):


 src,dst,weight_m
 

Vertices are created on demand from the CSV tokens via Integer::valueOf. Callers that need a different vertex type can build their own CSVImporter directly; this class is a convenience for the OSM road-graph case.

Author:
Shai Eilat