File tree Expand file tree Collapse file tree
src/main/java/org/opentripplanner/transit/model Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -486,7 +486,7 @@ private boolean containsSameStopsAsOriginalPattern() {
486486 * Helper method for getting the trip headsign from the {@link TripTimes}.
487487 */
488488 private I18NString getTripHeadSignFromTripTimes (TripTimes tripTimes ) {
489- return tripTimes != null ? tripTimes .getTrip (). getHeadsign () : null ;
489+ return tripTimes != null ? tripTimes .getTripHeadsign () : null ;
490490 }
491491
492492 /**
Original file line number Diff line number Diff line change @@ -212,6 +212,13 @@ public List<String> getHeadsignVias(final int stop) {
212212 return List .of (headsignVias [stop ]);
213213 }
214214
215+ /**
216+ * @return the whole trip's headsign. Individual stops can have different headsigns.
217+ */
218+ public I18NString getTripHeadsign () {
219+ return trip .getHeadsign ();
220+ }
221+
215222 /** @return the time in seconds after midnight that the vehicle arrives at the stop. */
216223 public int getScheduledArrivalTime (final int stop ) {
217224 return scheduledArrivalTimes [stop ] + timeShift ;
You can’t perform that action at this time.
0 commit comments