diff options
author | Daniel Friesel <derf@finalrewind.org> | 2015-06-23 22:12:48 +0200 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2015-06-23 22:12:48 +0200 |
commit | 1e048ee2f717e92b7ed89b1f0acd63b4953be83f (patch) | |
tree | 2629429827bd575b2e6a40647bdfc918cf68b734 /lib/Travel/Status/DE/EFA.pm | |
parent | 5106c6d18051685627e6775f48e61946ab192896 (diff) |
add new ::Stop class for stop data
Diffstat (limited to 'lib/Travel/Status/DE/EFA.pm')
-rw-r--r-- | lib/Travel/Status/DE/EFA.pm | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/Travel/Status/DE/EFA.pm b/lib/Travel/Status/DE/EFA.pm index 3ac28ce..ecf2b79 100644 --- a/lib/Travel/Status/DE/EFA.pm +++ b/lib/Travel/Status/DE/EFA.pm @@ -12,6 +12,7 @@ use Carp qw(confess cluck); use Encode qw(encode decode); use Travel::Status::DE::EFA::Line; use Travel::Status::DE::EFA::Result; +use Travel::Status::DE::EFA::Stop; use LWP::UserAgent; use XML::LibXML; @@ -334,15 +335,15 @@ sub parse_route { # cases. push( @ret, - { + Travel::Status::DE::EFA::Stop->new( arr_date => sprintf_date( $dates[0] ), arr_time => sprintf_time( $times[0] ), dep_date => sprintf_date( $dates[-1] ), dep_time => sprintf_time( $times[-1] ), - stop => decode( 'UTF-8', $e->getAttribute('name') ), - stop_suf => decode( 'UTF-8', $e->getAttribute('nameWO') ), + name => decode( 'UTF-8', $e->getAttribute('name') ), + name_suf => decode( 'UTF-8', $e->getAttribute('nameWO') ), platform => $e->getAttribute('platformName'), - } + ) ); } |