summaryrefslogtreecommitdiff
path: root/lib/Travel
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2015-01-16 15:46:52 +0100
committerDaniel Friesel <derf@finalrewind.org>2015-01-16 15:46:52 +0100
commit7829dbac4efa92d443a0a002ff3c0cf439514264 (patch)
tree7efb0d7dd9ae345c17b7b52133281afd11591fa6 /lib/Travel
parent1adf27e012dfdf9568dad030cbf25878c2dac1b5 (diff)
Result: Add ->type accessor (compatibility with other libs)
Diffstat (limited to 'lib/Travel')
-rw-r--r--lib/Travel/Status/DE/URA/Result.pm9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/Travel/Status/DE/URA/Result.pm b/lib/Travel/Status/DE/URA/Result.pm
index 2c13461..91953d5 100644
--- a/lib/Travel/Status/DE/URA/Result.pm
+++ b/lib/Travel/Status/DE/URA/Result.pm
@@ -52,6 +52,10 @@ sub time {
return $self->datetime->strftime('%H:%M:%S');
}
+sub type {
+ return 'Bus';
+}
+
sub route_timetable {
my ($self) = @_;
@@ -150,6 +154,11 @@ The stop ID belonging to this departure.
Departure time (HH:MM:SS).
+=item $departure->type
+
+Vehicle type for this departure. At the moment, this always returns "Bus".
+This option exists for compatibility with other Travel::Status libraries.
+
=back
=head2 INTERNAL