diff options
author | Daniel Friesel <derf@finalrewind.org> | 2015-06-19 15:43:17 +0200 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2015-06-19 15:43:17 +0200 |
commit | 5f3a234eb6eeb7626c7db0ed4a9b26afee042f05 (patch) | |
tree | dbd8c82493c4e62e4b92ee302ba712d53a3d1a79 /lib/Travel/Routing/DE/EFA/Route | |
parent | d5573d1d4ed6d193aee69956cc4403186a015e2f (diff) |
Route/Part: document current_notes and update regular_notes documentation
Diffstat (limited to 'lib/Travel/Routing/DE/EFA/Route')
-rw-r--r-- | lib/Travel/Routing/DE/EFA/Route/Part.pm | 25 |
1 files changed, 20 insertions, 5 deletions
diff --git a/lib/Travel/Routing/DE/EFA/Route/Part.pm b/lib/Travel/Routing/DE/EFA/Route/Part.pm index ab94b12..d308840 100644 --- a/lib/Travel/Routing/DE/EFA/Route/Part.pm +++ b/lib/Travel/Routing/DE/EFA/Route/Part.pm @@ -126,8 +126,11 @@ points, without interchanges for my $part ( $route->parts ) { - if ( $part->extra ) { - say join( "\n", $part->extra ); + if ( $part->regular_notes ) { + say join( "\n", $part->regular_notes ); + } + if ( $part->current_notes ) { + say join( "\n", map [ $_->{summary} ] $part->current_notes ); } printf( @@ -199,6 +202,18 @@ station, usually outlining how to transfer from this train to the next one List of URLs, may be empty. Each URL points to an HTML map of the arrival station. +=item $part->current_notes + +(NOT STABLE YET - return value may be changed without notice) + +Remarks about unscheduled changes to the line serving this connaction part, +such as cancelled stops. Most times, the EFA service does not include this +information in its route calculations. + +Returns a list of hashes. Each hash has the keys +summary, subject, subtitle and content. The former three return text strings, +while content returns HTML (also as a string). + =item $part->delay delay in minutes, 0 if unknown @@ -242,10 +257,10 @@ departure station, usually outlining how to transfer from thep previous train List of URLs, may be empty. Each URL poinst to an HTML map of the departure station. -=item $part->extra +=item $part->regular_notes -Additional information about the connection. Returns a list of -newline-terminated strings +Remarks about the line serving this connaction part. Returns a list of +strings. =item $part->train_destination |