Return street type in response

I would like to return the street type in the response *(e.g. highway, sec …). is it already there and I need to fetch it somehow? or I need to implement that in the encoder?

Currently that needs to be included in the FlagEncoder, yes. We are working on a better solution in https://github.com/graphhopper/graphhopper/issues/1112

Thanks Peter,
Will try a quick implementation in FE for the time being and will upgrade once the nicer solution is there.

I think I have to play with the wayFlags in the method handleWayTags(ReaderWay way, long allowed, long relationFlags) of the class CarFlagEncoder to add the street tzpe there in an efficient way. Unfortunately the logic is not so clear for me. any hints or doc. like how to add new propertzy without making damages to the other tags like speed,…

  1. init the typeEncodedValue via overwriting defineWayBits (call super.defineWayBits as first call) and
  2. in handleWayTags you call newFlags = typeEncodedValue.setValue(oldFlags, typeAsInt);

Then create a method like encoder.getType(long flags) so that you can use the encoder e.g. in your custom weighting that depends on the type

like how to add new propertzy without making damages to the other tags like speed,…

As long as you use EncodedValue or EncodedDoubleValue and init them in defineWayBits this is not possible