diff --git a/src/main/java/org/opentripplanner/street/search/state/State.java b/src/main/java/org/opentripplanner/street/search/state/State.java index b3f6c7e7ec2..37c3e81c097 100644 --- a/src/main/java/org/opentripplanner/street/search/state/State.java +++ b/src/main/java/org/opentripplanner/street/search/state/State.java @@ -5,7 +5,6 @@ import java.time.Instant; import java.util.ArrayList; import java.util.Collection; -import java.util.List; import java.util.Objects; import java.util.Set; import java.util.stream.Stream; @@ -482,21 +481,6 @@ public String toString() { .toString(); } - /** - * Iterates over all back states of this instance and returns them as a list. - *

- * Note: Use this only for debugging not for performance-critical paths! - */ - public List chain() { - List states = new ArrayList<>(); - State current = this; - while (current != null) { - states.add(current); - current = current.backState; - } - return states; - } - void checkNegativeWeight() { double dw = this.weight - backState.weight; if (dw < 0) {