summaryrefslogtreecommitdiff
path: root/lib/Travel
diff options
context:
space:
mode:
authorBirte Kristina Friesel <derf@finalrewind.org>2024-03-25 11:52:14 +0100
committerBirte Kristina Friesel <derf@finalrewind.org>2024-03-25 11:52:14 +0100
commitfc95f2a3ceef03f076ee268d71ce11d5765a6c37 (patch)
tree376f9733b06700c81cfb8b70c52663f4aaf57f15 /lib/Travel
parentff446b8a2d5d57aef30c4ed4fb2b536e6e56d141 (diff)
add --change-time / min_change_time options
Diffstat (limited to 'lib/Travel')
-rw-r--r--lib/Travel/Routing/DE/HAFAS.pm8
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/Travel/Routing/DE/HAFAS.pm b/lib/Travel/Routing/DE/HAFAS.pm
index 8ef5959..1ced8e8 100644
--- a/lib/Travel/Routing/DE/HAFAS.pm
+++ b/lib/Travel/Routing/DE/HAFAS.pm
@@ -243,7 +243,7 @@ sub new {
arrLocL => [ $self->stop_to_hafas( $self->{to_stop} ) ],
numF => 6,
maxChg => $conf{max_change},
- minChgTime => undef,
+ minChgTime => $conf{min_change_time},
outFrwd => $outFrwd,
viaLocL => @via_locs
? [ map { { loc => $_ } } @via_locs ]
@@ -760,6 +760,12 @@ pass an empty hashref to call the LWP::UserAgent constructor without arguments.
Request connections with no more than I<count> changeovers.
+=item B<min_change_time> => I<minutes>
+
+Request connections with scheduled changeover durations of at least I<minutes>.
+Note that this does not account for real-time data: the backend may return
+delayed connections that violate the specified changeover duration.
+
=item B<service> => I<service>
Request results from I<service>, defaults to "DB".