Travel::Status::DE::IRIS::Result - Information about a single arrival/departure received by Travel::Status::DE::IRIS
for my $result ($status->results) { printf( "At %s: %s to %s from platform %s\n", $result->time, $result->line, $result->destination, $result->platform, ); }
version 1.17
Travel::Status::DE::IRIs::Result describes a single arrival/departure as obtained by Travel::Status::DE::IRIS. It contains information about the platform, time, route and more.
Returns served stops which are not part of the schedule. I.e., this is the set of actual stops (route_post) minus the set of scheduled stops (sched_route_post).
DateTime(3pm) object for the arrival date and time. undef if the train starts here. Contains realtime data if available.
True if the arrival at this stop is an additional (unscheduled) event, i.e., if the train started its journey earlier than planned.
True if the arrival at this stop has been cancelled.
Returns a list of references to Travel::Status::DE::IRIS::Result(3pm) objects which are coupled to this train on arrival. Returns nothing (false / empty list) otherwise.
Returns stops which are scheduled, but will not be served by this train. I.e., this is the set of scheduled stops (sched_route_post) minus the set of actual stops (route_post).
List of characters indicating the class(es) of this train, may be empty. This is slighty related to type, but more generic. At this time, the following classes are known:
D Non-DB train. Usually local transport D,F Non-DB train, long distance transport F "Fernverkehr", long-distance transport N "Nahverkehr", local and regional transport S S-Bahn, rather slow local/regional transport
Scheduled departure date if available, arrival date otherwise (e.g. if the train ends here). String in dd.mm.YYYY format. Does not contain realtime data.
DateTime(3pm) object for departure if available, arrival otherwise. Does not contain realtime data.
Estimated delay in minutes (integer number). undef when no realtime data is available, negative if a train ends at the specified station and arrives / arrived early.
Get all delay messages entered for this train. Returns a list of [datetime, string] listrefs sorted by newest first. The datetime part is a DateTime(3pm) object corresponding to the point in time when the message was entered, the string is the message. If a delay reason was entered more than once, only its most recent record will be returned.
DateTime(3pm) object for the departure date and time. undef if the train ends here. Contains realtime data if available.
True if the train's departure at this stop is unscheduled (additional), i.e., the route has been extended past its scheduled terminal stop.
True if the train's departure at this stop has been cancelled, i.e., the train terminates here and does not continue its scheduled journey.
Returns a list of references to Travel::Status::DE::IRIS::Result(3pm) objects which are coupled to this train on departure. Returns nothing (false / empty list) otherwise.
Alias for route_end.
List of information strings. Contains both reasons for delays (which may or may not be up-to-date) and generic information such as missing carriages or broken toilets.
True if the train's arrival and departure at the stop are unscheduled additional stops, false otherwise.
True if the train was cancelled, false otherwise. Note that this does not contain information about replacement trains or route diversions.
True if the train changes its ID at the current station, false otherwise.
An ID change means: There are two results in the system (e.g. RE 10228 Münster -> Duisburg, RE 30028 Duisburg -> Düsseldorf), but they are the same train (RE line 2 from Münster to Düsseldorf in this case) and should be treated as such. In this case, Travel::Status::DE::IRIS merges the results and indicates it by setting is_transfer to a true value.
In case of a transfer, train_id and train_no are set to the "new" value, the old ones are available in old_train_id and old_train_no.
True if the train does not appear in the requested plans. This can happen because of two reasons: Either the scheduled time and the actual time are so far apart that it should've arrived/departed long ago, or it really is an unscheduled train. In that case, it can be a replacement or an additional train. There is no logic to distinguish these cases yet.
Returns true if this result is a wing, false otherwise. A wing is a train which has its own ID and destination, but is currently coupled to another train and shares all or some of its route.
Train type with line (such as S 1) if available, type with number (suc as RE 10126) otherwise.
S 1
RE 10126
Number of the line, undef if unknown. Seems to be set only for S-Bahn and regional trains. Note that some regional and most long-distance trains do not have this field set, even if they have a common line number.
Example: For the line S 1, line_no will return 1.
1
Get all qos and delay messages ever entered for this train. Returns a list of [datetime, string] listrefs sorted by newest first. The datetime part is a DateTime(3pm) object corresponding to the point in time when the message was entered, the string is the message. Note that neither duplicates nor superseded messages are filtered from this list.
Numeric ID of the pre-transfer train. Seems to be unique for a year and trackable across stations. Only defined if a transfer took place, see also is_transfer.
Number of the pre-tarnsfer train, unique per day. E.g. 2225 for IC 2225. See also is_transfer. Only defined if a transfer took place, see also is_transfer.
2225
IC 2225
Alias for route_start.
Get all current qos messages for this train. Returns a list of [datetime, string] listrefs sorted by newest first. The datetime part is a DateTime(3pm) object corresponding to the point in time when the message was entered, the string is the message. Contains neither superseded messages nor duplicates (in case of a duplicate, only the most recent message is present)
Arrival/departure platform as string, undef if unknown. Note that this is not neccessarily a number, platform sections may be included (e.g. 3a/b).
3a/b
Raw ID of the departure, e.g. -4642102742373784975-1401031322-6. The first part appears to be this train's UUID (can be tracked across multiple stations), the second the YYmmddHHMM departure timestamp at its start station, and the third the count of this station in the train's schedule (in this case, it's the sixth from thestart station).
-4642102742373784975-1401031322-6
About half of all departure IDs do not contain the leading minus (-) seen in this example. The reason for this is unknown.
-
This is a developer option. It may be removed without prior warning.
XML::LibXML::Node(3pm) object containing all realtime data. undef if none is available.
Returns a list of references to Travel::Status::DE::IRIS::Result(3pm) objects which replace the (usually cancelled) arrival/departure of this train. Returns nothing (false / empty list) otherwise.
Returns a list of references to Travel::Status::DE::IRIS::Result(3pm) objects which this (usually unplanned) train is meant to replace. Returns nothing (false / empty list) otherwise.
List of all stations served by this train, according to its schedule. Does not contain realtime data.
Name of the last station served by this train.
List of up to three "interesting" stations served by this train, subset of route_post. Usually contains the next stop and one or two major stations after that. Does not contain realtime data.
List of station names the train passed (or will have passed) befoe this stop.
List of station names the train will pass after this stop.
Name of the first station served by this train.
DateTime(3pm) object for the scheduled arrival date and time. undef if the train starts here.
DateTime(3pm) object for the scehduled departure date and time. undef if the train ends here.
Scheduled Arrival/departure platform as string, undef if unknown. Note that this is not neccessarily a number, platform sections may be included (e.g. 3a/b).
Name of the last station served by this train according to its schedule.
List of station names the train is scheduled to pass before this stop.
List of station names the train is scheduled to pass after this stop.
Name of the first station served by this train according to its schedule.
DateTime(3pm) object for the scheduled start of the train on its route (i.e. the departure time at its first station).
Number of this stop on the train's route. 1 if it's the start station, 2 for the stop after that, and so on.
Scheduled departure time if available, arrival time otherwise (e.g. if the train ends here). String in HH:MM format. Does not contain realtime data.
Alias for line.
Numeric ID of this train, trackable across stations and days. For instance, the S 31128 (S1) to Solingen, starting in Dortmund on 19:23, has the ID 2404170432985554630 on each station it passes and (usually) on every day of the year. Note that it may change during the yearly itinerary update in december.
Number of this train, unique per day. E.g. 2225 for IC 2225.
Type of this train, e.g. S for S-Bahn, RE for Regional-Express, ICE for InterCity-Express.
S
RE
ICE
Returns a new Travel::Status::DE::IRIS::Result object. You usually do not need to call this.
A dump of all messages entered for the result is available. Each message consists of a timestamp (when it was entered), a type (d for delay reasons, q for other train-related information) and a value (numeric ID).
At the time of this writing, the following messages are known:
Source: Correlation between IRIS and DB RIS (bahn.de).
Source: Correlation between IRIS and DB RIS (bahn.de). Several entries, related to "Notarzteinsatz am Gleis".
Source: correlation between IRIS and DB RIS (bahn.de).
Verified by https://iris.noncd.db.de/irisWebclient/Configuration.
Obsoletes messages 80, 82, 83, 85. Verified by https://iris.noncd.db.de/irisWebclient/Configuration.
Obsoletes messages 80, 82, 83, 85, 86, 87, 90, 91, 92, 93, 96, 97, 98. Verified by https://iris.noncd.db.de/irisWebclient/Configuration.
Obsoletes messages 86, 87. Verified by https://iris.noncd.db.de/irisWebclient/Configuration.
Might also mean "Keine Fahrradmitnahme" (source: frubi).
Might also mean "Rollstuhlgerechtes WC in einem Wagen ausgefallen" (source: frubi).
Verified by https://iris.noncd.db.de/irisWebclient/Configuration. Might also mean "Kein rollstuhlgerechtes WC" (source: frubi).
Estimated from a comparison with bahn.de/ris messages. Needs to be verified.
Estimated from a comparison with bahn.de/iris messages.
Verified by https://iris.noncd.db.de/irisWebclient/Configuration. Might also mean "Kein rollstuhlgerechter Wagen" (source: frubi).
Verified by correlation. Not sure yet.
None.
Unknown.
Travel::Status::DE::IRIS(3pm).
Copyright (C) 2013-2018 by Daniel Friesel <derf@finalrewind.org>
This module is licensed under the same terms as Perl itself.
To install Travel::Status::DE::IRIS, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Travel::Status::DE::IRIS
CPAN shell
perl -MCPAN -e shell install Travel::Status::DE::IRIS
For more information on module installation, please visit the detailed CPAN module installation guide.