Skip to content

Commit

Permalink
Initial revision
Browse files Browse the repository at this point in the history
  • Loading branch information
drhyde committed Mar 9, 2007
0 parents commit b296864
Show file tree
Hide file tree
Showing 8 changed files with 97 additions and 0 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG
@@ -0,0 +1,3 @@
2006-08-25 Fixed test to work with fixed Number::Phone::UK
2006-08-24 Updated dependencies to avoid buggy Number::Phone::UK. Doh!
2006-08-23 Initial release
8 changes: 8 additions & 0 deletions MANIFEST
@@ -0,0 +1,8 @@
lib/Number/Phone/UK/DetailedLocations.pm
t/00_detailed_locations.t
MANIFEST
lib/Number/Phone/UK/DetailedLocations.pod
Makefile.PL
CHANGELOG
README
META.yml Module meta-data (added by MakeMaker)
11 changes: 11 additions & 0 deletions META.yml
@@ -0,0 +1,11 @@
# http://module-build.sourceforge.net/META-spec.html
#XXXXXXX This is a prototype!!! It will change in the future!!! XXXXX#
name: Number-Phone-UK-DetailedLocations
version: 1.2
version_from:
installdirs: site
requires:
Number::Phone::UK: 1.55

distribution_type: module
generated_by: ExtUtils::MakeMaker version 6.30
8 changes: 8 additions & 0 deletions Makefile.PL
@@ -0,0 +1,8 @@
use ExtUtils::MakeMaker;
WriteMakefile(
NAME => 'Number::Phone::UK::DetailedLocations',
VERSION => '1.2',
PREREQ_PM => {
'Number::Phone::UK' => 1.55,
}
);
13 changes: 13 additions & 0 deletions README
@@ -0,0 +1,13 @@
This module does nothing on its own, but is an add-on for Number::Phone::UK,
to make the location() method more accurate. I decided to distribute it
seperately because to include all this data as well as that for the national
numbering scheme would make the module ridiculously big. Better to have this,
which will not be needed so often and is updated far less often, as a seperate
package.

To install it, do the usual dance:

perl Makefile.PL
make
make test
make install
Binary file added lib/Number/Phone/UK/DetailedLocations.pm
Binary file not shown.
44 changes: 44 additions & 0 deletions lib/Number/Phone/UK/DetailedLocations.pod
@@ -0,0 +1,44 @@
=head1 NAME

Number::Phone::UK::DetailedLocations - more detailed location information for Nu
mber::Phone::UK

=head1 SYNOPSIS

Just install it, and Number::Phone::UK will magically pick it up and use it
instead of the restricted data set distributed with it.

=head1 ACCURACY

The data in this add-on module is more accurate than that distributed with
Number::Phone because Number::Phone only has location data for one of the
several exchanges serving each area code. This is therefore a superset of
that data.

The latitude and longitude data has several more significant figures than it
deserves, simply because that's what was in the datasource I got it from.

=head1 LIMITATIONS/BUGS/FEEDBACK

This module contains the locations of most BT phone exchanges, and the
number ranges handled by them. However, the data is (at the time of writing)
nearly a year old. I can't find a more recent source. Thankfully, this
sort of data doesn't go stale quickly. New exchanges hardly ever open, and
while new number ranges may be assigned to exchanges, they will for at least
a few years be a small proportion of all numbers.

If you find any errors, please report them by email.

=head1 LICENCE

You may use, modify and distribute this software under the same terms as
perl itself.

=head1 AUTHOR

David Cantrell E<lt>david@cantrell.org.ukE<gt>

Copyright 2006

=cut

10 changes: 10 additions & 0 deletions t/00_detailed_locations.t
@@ -0,0 +1,10 @@
#!/usr/bin/perl

use strict;
use warnings;
use Number::Phone::UK;

use Test::More tests => 1;

my $number = Number::Phone::UK->new('02087712924');
is_deeply($number->location(), [51.410357, -0.08641], "Yarr, it all works");

0 comments on commit b296864

Please sign in to comment.