Hey there developers!
I’m pretty new to the GraphHopper Code. So please bare with me. I have setup the complete environment and this works. Also I’ve added my own FlagEncoder. Now I want to change the routing code.
I have the following problem: I want to introduce a new parameter to the Routing API endpoint (module graphhopper-api
), where I can set e.g. maxwidth of the vehicle. This information should be used (I guess) in the core (module graphhopper-core
) to consider it when calculating the route. Currently GraphHopper only considers maxwidth of ways (as I know). I want to extend the functionality to also consider nodes which contain width information. So my question is: Where to start? Is there a main starting point where in the code I can implement this at first, maybe hardcoded width of the vehicle without the api in the first place?
My plan was currently: I need to add the tags on nodes I want, to the FlagEncoder
analog to potentialBarriers
(like in BikeCommonFlagEncoder
) with the width information. Then the information is in the Graph. Can I save this information via a HashMap for example and how?
For parsing I could use the OSMMaxWidthParser
, I guess.
And now , how to consider it when routing is executed? Where to hook on?
I would be very grateful for help!
Thank you and Regards.