line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package GeoIP2::Model::Domain; |
2
|
|
|
|
|
|
|
|
3
|
7
|
|
|
7
|
|
48
|
use strict; |
|
7
|
|
|
|
|
15
|
|
|
7
|
|
|
|
|
207
|
|
4
|
7
|
|
|
7
|
|
32
|
use warnings; |
|
7
|
|
|
|
|
21
|
|
|
7
|
|
|
|
|
250
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
our $VERSION = '2.006002'; |
7
|
|
|
|
|
|
|
|
8
|
7
|
|
|
7
|
|
30
|
use Moo; |
|
7
|
|
|
|
|
14
|
|
|
7
|
|
|
|
|
40
|
|
9
|
|
|
|
|
|
|
|
10
|
7
|
|
|
7
|
|
2223
|
use GeoIP2::Types qw( IPAddress Str ); |
|
7
|
|
|
|
|
22
|
|
|
7
|
|
|
|
|
463
|
|
11
|
|
|
|
|
|
|
|
12
|
7
|
|
|
7
|
|
46
|
use namespace::clean -except => 'meta'; |
|
7
|
|
|
|
|
22
|
|
|
7
|
|
|
|
|
59
|
|
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
with 'GeoIP2::Role::Model::Flat', 'GeoIP2::Role::HasIPAddress'; |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
has domain => ( |
17
|
|
|
|
|
|
|
is => 'ro', |
18
|
|
|
|
|
|
|
isa => Str, |
19
|
|
|
|
|
|
|
predicate => 'has_domain', |
20
|
|
|
|
|
|
|
); |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
1; |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
# ABSTRACT: Model class for the GeoIP2 Domain database |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
__END__ |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
=pod |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
=encoding UTF-8 |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
=head1 NAME |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
GeoIP2::Model::Domain - Model class for the GeoIP2 Domain database |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
=head1 VERSION |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
version 2.006002 |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
=head1 SYNOPSIS |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
use 5.008; |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
use GeoIP2::Model::Domain; |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
my $domain = GeoIP2::Model::Domain->new( |
47
|
|
|
|
|
|
|
raw => { domain => 'maxmind.com', ip_address => '24.24.24.24'} |
48
|
|
|
|
|
|
|
); |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
print $domain->domain(), "\n"; |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
=head1 DESCRIPTION |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
This class provides a model for the data returned by the GeoIP2 Domain |
55
|
|
|
|
|
|
|
database. |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
=head1 METHODS |
58
|
|
|
|
|
|
|
|
59
|
|
|
|
|
|
|
This class provides the following methods: |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
=head2 $domain->domain() |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
Returns the domain as a string. |
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
=head2 $domain->ip_address() |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
Returns the IP address used in the lookup. |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
=head1 SUPPORT |
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
Bugs may be submitted through L<https://github.com/maxmind/GeoIP2-perl/issues>. |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
=head1 AUTHORS |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
=over 4 |
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
=item * |
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
Dave Rolsky <drolsky@maxmind.com> |
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
=item * |
82
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
Greg Oschwald <goschwald@maxmind.com> |
84
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
=item * |
86
|
|
|
|
|
|
|
|
87
|
|
|
|
|
|
|
Mark Fowler <mfowler@maxmind.com> |
88
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
=item * |
90
|
|
|
|
|
|
|
|
91
|
|
|
|
|
|
|
Olaf Alders <oalders@maxmind.com> |
92
|
|
|
|
|
|
|
|
93
|
|
|
|
|
|
|
=back |
94
|
|
|
|
|
|
|
|
95
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
96
|
|
|
|
|
|
|
|
97
|
|
|
|
|
|
|
This software is copyright (c) 2013 - 2019 by MaxMind, Inc. |
98
|
|
|
|
|
|
|
|
99
|
|
|
|
|
|
|
This is free software; you can redistribute it and/or modify it under |
100
|
|
|
|
|
|
|
the same terms as the Perl 5 programming language system itself. |
101
|
|
|
|
|
|
|
|
102
|
|
|
|
|
|
|
=cut |