NAME
Map::Tube::Node - Defines the node for Map::Tube
VERSION
Version 1.0
SYNOPSIS
Here is sample map
B -------- C
/ \ / \
/ \ / \
/ \ / \
A ------ G ------- D
\ / \ /
\ / \ /
\ / \ /
F -------- E
/
/
/
H
\
\
\
I
which can be defined as below:
{ 'A' => ['B','F','G'], 'B' => ['A','C','G'], 'C' => ['B','D','G'], 'D' => ['C','E','G'], 'E' => ['D','F','G'], 'F' => ['A','E','G','H'], 'G' => ['A','B','C','D','E','F'], 'H' => ['F','I'], 'I' => ['H'] }
METHODS
init()
This is the core method of the module, where we actually define the relationship among the diffrerent nodes. I have taken extra care to depict the relationship. However I would be more than happy to receieve any suggestion to improve the logic. Please note "Transport for London" is the owner of the data used here.
load_element()
This loads all the nodes defined. Currently covers Bakerloo, Central, Circle, District, Hammersmith & City, Jubilee, Metropolitan, Northern, Piccadilly and Victoria. I shall be finishing the last remaining Waterloo & City line very soon. Please note this is still very experimental in nature.
upcase_element_name
This loads all the nodes with name in uppercase. This is to allow case-insensitive name lookup. User can also provide the node list otherwise it will pick the default list.
AUTHOR
Mohammad S Anwar, <mohammad.anwar@yahoo.com>
BUGS
Please report any bugs or feature requests to bug-map-tube@rt.cpan.org
, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Map-Tube. 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 Map::Tube::Node
You can also look for information at:
RT: CPAN's request tracker
AnnoCPAN: Annotated CPAN documentation
CPAN Ratings
Search CPAN
LICENSE AND COPYRIGHT
Copyright 2010 Mohammad S Anwar.
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.