# Graphhopper RoundTrip with x seconds pause for every point

Hi there,

is ist possible to do a graphhopper request with 10 points and make a pause of 30 sek on every reached point. So that the pathe details for time have point 0 at time 0:00 point 1 at 2:00 and than pont 1 with 2:30 and than starts routing to point 3 and so on?

This is intresting for RoundTrips for package deliverys or trucker

I’m thankfull for any help

Do you mean solving an unknown route?
Just add 30 seconds service time.

If you know the route and are outputting the time, just add 30 seconds to each time.
Either iterate over path results or assess each point to point relation independently

point 0 > 1 takes 2:00. New time1 = 120 + 30
point 1 > 2 takes 3:00. New time2 = 180 + 30
Total time = New time1 + New time2

Something like that?

Somthing like that but without making a new routing request.

If you have 5 points you want to visit you can do new GHReqest(new List<.GhPoints>())

The result route visits all 5 points. Is it possible to do new GHReqest(new List<.GhPoints>(), 5sek PAUSE_BETWEEN_POINTS)?

It would suck to do:
new GHRequest(P_1, P_2) Time1 += 30sek
new GHRequest(P_2, P_3) Time2 += 30sek
new GHRequest(P_3, P_4) Time3 += 30sek

Total time = SUM(TIME_i)_i={1…5}

If you are just wanting total time cant you just do
newTimeInSeconds = routeTimeInSeconds + request.getPoints().size() * 30

If you are wanting to assess times between each point you will need to iterate over the path.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.