Travel::Status::DE::HAFAS::Result - Information about a single arrival/departure received by Travel::Status::DE::HAFAS
for my $departure ($status->results) { printf( "At %s: %s to %s from platform %s\n", $departure->time, $departure->line, $departure->destination, $departure->platform, ); } # or (depending on module setup) for my $arrival ($status->results) { printf( "At %s: %s from %s on platform %s\n", $arrival->time, $arrival->line, $arrival->origin, $arrival->platform, ); }
version 3.01
Travel::Status::DE::HAFAS::Result describes a single arrival/departure as obtained by Travel::Status::DE::HAFAS. It contains information about the platform, time, route and more.
Difference between the time Travel::Status::DE::HAFAS->results was called first and the arrival/departure time, in minutes.
Difference between the time Travel::Status::DE::HAFAS->results was called first and the arrival/departure time, in seconds.
Arrival/Departure date in "dd.mm.yyyy" format.
DateTime object holding the arrival/departure date and time.
Returns the delay in minutes, or undef if it is unknown. Also returns undef if the arrival/departure has been cancelled.
Returns additional information, for instance the most recent delay reason. undef if no (useful) information is available.
True if the arrival/departure was cancelled, false otherwise.
True if the platform (as returned by the platform accessor) is not the scheduled one. Note that the scheduled platform is unknown in this case.
Returns a list of message strings related to this result. Messages usually are service notices (e.g. "missing carriage") or detailed delay reasons (e.g. "switch damage between X and Y, expect delays").
Returns the line name, either in a format like "Bus SB16" (Bus line SB16) or "RE 10111" (RegionalExpress train 10111, no line information). May contain extraneous whitespace characters.
Returns the line/train number, for instance "SB16" (bus line SB16), "11" (Underground train line U 11) or 1011 ("RegionalExpress train 1011"). Note that this may not be a number at all: Some transport services also use single-letter characters or words (e.g. "AIR") as line numbers.
Returns the operator responsible for this arrival/departure. Returns undef if the backend does not provide an operator.
Note that ÖBB is the only known backend providing this information.
Returns the arrival/departure platform. Realtime data if available, schedule data otherwise.
Returns the last element of the route. Depending on how you set up Travel::Status::DE::HAFAS (arrival or departure listing), this is either the result's destination or its origin station.
Scheduled arrival/departure date in "dd.mm.yyyy" format.
DateTime object holding the scheduled arrival/departure date and time.
Scheduled arrival/departure time in "hh:mm" format.
Arrival/Departure time in "hh:mm" format.
Returns the type of this result, e.g. "S" for S-Bahn, "RE" for Regional Express or "STR" for tram / Straßenbahn.
None.
None known.
Travel::Status::DE::HAFAS(3pm).
Copyright (C) 2015-2020 by Daniel Friesel <derf@finalrewind.org>
This module is licensed under the same terms as Perl itself.