GeoIP2.pm untested

filter: Statementstmt 0.0% 0 / 11 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 3 Podpod n/a totaltotal 0.0% 0 / 14 CC 1 SCAR 6.9
CC
1
Cov
0%
BEGIN
2.0
BEGIN
2.0
BEGIN
2.0
CRAP 2.0
1 package GeoIP2;
2  
3 use 5.008;
4 use strict;
5 use warnings;
6  
7 our $VERSION = '2.006000';
8  
9 1;
10  
11 # ABSTRACT: Perl API for MaxMind's GeoIP2 web services and databases
12  
13 __END__
14  
15 =pod
16  
17 =encoding UTF-8
18  
19 =head1 NAME
20  
21 GeoIP2 - Perl API for MaxMind's GeoIP2 web services and databases
22  
23 =head1 VERSION
24  
25 version 2.006000
26  
27 =head1 DESCRIPTION
28  
29 This distribution provides an API for the GeoIP2
30 L<web services|http://dev.maxmind.com/geoip/geoip2/web-services> and
31 L<databases|http://dev.maxmind.com/geoip/geoip2/downloadable>. The API also
32 works with the free
33 L<GeoLite2 databases|http://dev.maxmind.com/geoip/geoip2/geolite2/>.
34  
35 See L<GeoIP2::WebService::Client> for details on the web service client API
36 and L<GeoIP2::Database::Reader> for the database API.
37  
38 =head1 SPEEDING UP DATABASE READING
39  
40 This module only depends on the pure Perl implementation of the MaxMind
41 database reader (L<MaxMind::DB::Reader>). If you install the libmaxminddb
42 library (L<http://maxmind.github.io/libmaxminddb/>) and
43 L<MaxMind::DB::Reader::XS>, then the XS implementation will be loaded
44 automatically. The XS implementation is approximately 100x faster than the
45 pure Perl implementation.
46  
47 =head1 VALUES TO USE FOR DATABASE OR HASH KEYS
48  
49 B<We strongly discourage you from using a value from any C<names> accessor as
50 a key in a database or hash.>
51  
52 These names may change between releases. Instead we recommend using one of the
53 following:
54  
55 =over 4
56  
57 =item * L<GeoIP2::Record::City> - C<< $city->geoname_id >>
58  
59 =item * L<GeoIP2::Record::Continent> - C<< $continent->code >> or C<< $continent->geoname_id >>
60  
61 =item * L<GeoIP2::Record::Country> and L<GeoIP2::Record::RepresentedCountry> - C<< $country->iso_code >> or C<< $country->geoname_id >>
62  
63 =item * L<GeoIP2::Record::Subdivision> - C<< $subdivision->iso_code >> or C<< $subdivision->geoname_id >>
64  
65 =back
66  
67 =head1 INTEGRATION WITH GEONAMES
68  
69 GeoNames (L<http://www.geonames.org/>) offers web services and downloadable
70 databases with data on geographical features around the world, including
71 populated places. They offer both free and paid premium data. Each feature is
72 uniquely identified by a C<geoname_id>, which is an integer.
73  
74 Many of the records returned by the GeoIP web services and databases include a
75 C<geoname_id> field. This is the ID of a geographical feature (city, region,
76 country, etc.) in the GeoNames database.
77  
78 Some of the data that MaxMind provides is also sourced from GeoNames. We
79 source data such as place names, ISO codes, and other similar data from the
80 GeoNames premium data set.
81  
82 =head1 REPORTING DATA PROBLEMS
83  
84 If the problem you find is that an IP address is incorrectly mapped, please
85 submit your correction to MaxMind at L<http://www.maxmind.com/en/correction>.
86  
87 If you find some other sort of mistake, like an incorrect spelling, please
88 check the GeoNames site (L<http://www.geonames.org/>) first. Once you've searched
89 for a place and found it on the GeoNames map view, there are a number of links
90 you can use to correct data ("move", "edit", "alternate names", etc.). Once
91 the correction is part of the GeoNames data set, it will be automatically
92 incorporated into future MaxMind releases.
93  
94 If you are a paying MaxMind customer and you're not sure where to submit a
95 correction, please contact MaxMind support at for help. See
96 L<http://www.maxmind.com/en/support> for support details.
97  
98 =head1 VERSIONING POLICY
99  
100 This module uses semantic versioning as described by
101 L<http://semver.org/>. Version numbers can be read as X.YYYZZZ, where X is the
102 major number, YYY is the minor number, and ZZZ is the patch number.
103  
104 =head1 PERL VERSION SUPPORT
105  
106 MaxMind has tested this API with Perl 5.8.8 and above. Reasonable patches for
107 earlier versions of Perl 5.8 will be applied. We will not accept patches to
108 support any version of Perl before 5.8.
109  
110 The data returned from the GeoIP2 web services includes Unicode characters in
111 several locales. This may expose bugs in earlier versions of Perl. If Unicode
112 support is important to you, we recommend that you use the most recent version
113 of Perl available.
114  
115 =head1 SUPPORT
116  
117 Please report all issues with this code using the GitHub issue tracker at
118 L<https://github.com/maxmind/GeoIP2-perl/issues>.
119  
120 If you are having an issue with a MaxMind service that is not specific to the
121 client API please see L<http://www.maxmind.com/en/support> for details.
122  
123 =head1 AUTHORS
124  
125 =over 4
126  
127 =item *
128  
129 Dave Rolsky <drolsky@maxmind.com>
130  
131 =item *
132  
133 Greg Oschwald <goschwald@maxmind.com>
134  
135 =item *
136  
137 Mark Fowler <mfowler@maxmind.com>
138  
139 =item *
140  
141 Olaf Alders <oalders@maxmind.com>
142  
143 =back
144  
145 =head1 CONTRIBUTORS
146  
147 =for stopwords Andy Jack E. Choroba Florian Ragwitz Graham Knop Mateu X Hunter Michael F. Canzoneri Narsimham Chelluri Patrick Cronin William Storey
148  
149 =over 4
150  
151 =item *
152  
153 Andy Jack <github@veracity.ca>
154  
155 =item *
156  
157 E. Choroba <choroba@matfyz.cz>
158  
159 =item *
160  
161 Florian Ragwitz <rafl@debian.org>
162  
163 =item *
164  
165 Graham Knop <haarg@haarg.org>
166  
167 =item *
168  
169 Mateu X Hunter <mhunter@maxmind.com>
170  
171 =item *
172  
173 Michael F. Canzoneri <mikecanzoneri@gmail.com>
174  
175 =item *
176  
177 Narsimham Chelluri <nchelluri@users.noreply.github.com>
178  
179 =item *
180  
181 Patrick Cronin <PatrickCronin@users.noreply.github.com>
182  
183 =item *
184  
185 William Storey <wstorey@maxmind.com>
186  
187 =back
188  
189 =head1 COPYRIGHT AND LICENSE
190  
191 This software is copyright (c) 2013 - 2018 by MaxMind, Inc.
192  
193 This is free software; you can redistribute it and/or modify it under
194 the same terms as the Perl 5 programming language system itself.
195  
196 =cut