Why not adopt me?
NAME
WWW::EFA - Interface to EFA sites (Elektronische Fahrplanauskunft)
VERSION
Version 0.01
SYNOPSIS
Get location of public transport stops and connection details.
use WWW::EFA;
my $efa = WWW::EFA->new();
...
PARAMS/ACCESSORS
METHODS
departures
Queries the XSLT_DM_REQUEST method from the EFA server.
Params:
location => A WWW::EFA::Location object which must have the id (stopID) defined
trips
Queries the XSLT_TRIP_REQUEST2 method from the EFA server.
Required Params:
from => WWW::EFA::Location object
to => WWW::EFA::Location object
date => Class::Date object of the time to be searched
Optional Params:
via => WWW::EFA::Location object. Default undef
is_departure => set to true if the date is the departure time, otherwise arrival time. Default 0
language => Language to return results in. Default 'de'
walk_speed => Override default walk speed. TODO: RCL 2011-08-23 What is walk speed? km/h? m/s?
stop_finder
Queries the XML_STOPFINDER_REQUEST method from the EFA server.
Used to get an address from coordinates
Usage:
my $location = WWW::EFA::Location->new( coordinates => WWW::EFA::Coordinates->new( lat => 12.12345, lon => 48.12345, );
my( $address ) = $efa->stop_finder( location => $location, );
Params:
location => L<WWW::EFA::Location> object
Returns an ArrayRef of WWW::EFA::Location objects.
coord_request
Queries the XML_COORD_REQUEST method from the EFA server.
Params:
location => A WWW::EFA::Location object with either id or lon/lat defined
max_results => Maximum number of results to return
max_distance => Maximum distance (meters) around the given location to search
Returns an array reference of WWW::EFA::Location objects.
complete_location_from_anything
Give me an id, lat/lon, latitude/longitude, or location, and I will make sure it is complete with id and coordinates Handy because in some contexts we don't have a complete location object...
AUTHOR
Robin Clarke, <perl at robinclarke.net>
BUGS
Please report any bugs or feature requests to bug-www-efa at rt.cpan.org
, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=WWW-EFA. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
SUPPORT
You can find documentation for this module with the perldoc command.
perldoc WWW::EFA
You can also look for information at:
RT: CPAN's request tracker (report bugs here)
AnnoCPAN: Annotated CPAN documentation
CPAN Ratings
Search CPAN
ACKNOWLEDGEMENTS
LICENSE AND COPYRIGHT
Copyright 2011 Robin Clarke.
This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.
See http://dev.perl.org/licenses/ for more information.