forked from lebotlan/BE-Graphes
made getTravelTime()
This commit is contained in:
parent
5140e88075
commit
2f523b12c3
1 changed files with 5 additions and 3 deletions
|
|
@ -208,11 +208,13 @@ public class Path {
|
||||||
* @param speed Speed to compute the travel time.
|
* @param speed Speed to compute the travel time.
|
||||||
* @return Time (in seconds) required to travel this path at the given speed (in
|
* @return Time (in seconds) required to travel this path at the given speed (in
|
||||||
* kilometers-per-hour).
|
* kilometers-per-hour).
|
||||||
* @deprecated Need to be implemented.
|
|
||||||
*/
|
*/
|
||||||
public double getTravelTime(double speed) {
|
public double getTravelTime(double speed) {
|
||||||
// TODO:
|
double ttime = 0;
|
||||||
return 0;
|
for (Arc thisArc : arcs) {
|
||||||
|
ttime += thisArc.getTravelTime(speed);
|
||||||
|
}
|
||||||
|
return ttime;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue