I am using GraphHopper to import OSM data and transform it to graph-based format for a certain program that we are currently using.
As we only work with one country's data at any time, I would like to use an class AreaSpecificCarFlagEncoder extends CarFlagEncoder that would receive the speed limits for a given area in beginning of work of the program.
(More sophisticated) alternative: input for AreaSpecificCarFlagEncoder would be N sets of (WKT geometries and sets of speed limits). AreaSpecificCarFlagEncoder would make sure that the geometries are non-intersecting; and if given way is fully in some area, then the given speed limit is used. If way is not inside any of the given areas, default values are used.
I do not know what would be the best course of action if way is partially in one or more areas. Perhaps it would be most suitable to use default speeds then.
Please comment.
I am using GraphHopper to import OSM data and transform it to graph-based format for a certain program that we are currently using.
As we only work with one country's data at any time, I would like to use an class AreaSpecificCarFlagEncoder extends CarFlagEncoder that would receive the speed limits for a given area in beginning of work of the program.
(More sophisticated) alternative: input for AreaSpecificCarFlagEncoder would be N sets of (WKT geometries and sets of speed limits). AreaSpecificCarFlagEncoder would make sure that the geometries are non-intersecting; and if given way is fully in some area, then the given speed limit is used. If way is not inside any of the given areas, default values are used.
I do not know what would be the best course of action if way is partially in one or more areas. Perhaps it would be most suitable to use default speeds then.
Please comment.