Class OptionalTurnCostProvider

  • All Implemented Interfaces:
    com.graphhopper.routing.weighting.TurnCostProvider

    public class OptionalTurnCostProvider
    extends Object
    implements com.graphhopper.routing.weighting.TurnCostProvider
    • Constructor Detail

      • OptionalTurnCostProvider

        public OptionalTurnCostProvider​(VehicleEncoding encoding,
                                        com.graphhopper.storage.TurnCostStorage turnCostStorage)
    • Method Detail

      • disableTurnCosts

        public com.graphhopper.routing.weighting.TurnCostProvider disableTurnCosts()
        Disables consideration of turn costs. Only turn restrictions are checked.
      • calcTurnWeight

        public double calcTurnWeight​(int edgeFrom,
                                     int nodeVia,
                                     int edgeTo)
        Specified by:
        calcTurnWeight in interface com.graphhopper.routing.weighting.TurnCostProvider
      • calcTurnMillis

        public long calcTurnMillis​(int inEdge,
                                   int viaNode,
                                   int outEdge)
        Specified by:
        calcTurnMillis in interface com.graphhopper.routing.weighting.TurnCostProvider