| 1 | package GeoIP2::Record::Location; | ||
| 2 | |||
| 3 | 12 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 4 | 12 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 5 | |||
| 6 | 12 | our $VERSION = '2.006002'; | |
| 7 | |||
| 8 | 12 | ▶ | use Moo; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 9 | |||
| 10 | 12 | ▶ | use GeoIP2::Types qw( NonNegativeInt Num PositiveInt Str ); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 11 | |||
| 12 | 12 | ▶ | use namespace::clean -except => 'meta'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 13 | |||
| 14 | 12 | has accuracy_radius => ( | |
| 15 | is => 'ro', | ||
| 16 | isa => PositiveInt, | ||
| 17 | predicate => 'has_accuracy_radius', | ||
| 18 | ); | ||
| 19 | |||
| 20 | 12 | has average_income => ( | |
| 21 | is => 'ro', | ||
| 22 | isa => NonNegativeInt, | ||
| 23 | predicate => 'has_average_income', | ||
| 24 | ); | ||
| 25 | |||
| 26 | 12 | has latitude => ( | |
| 27 | is => 'ro', | ||
| 28 | isa => Num, | ||
| 29 | predicate => 'has_latitude', | ||
| 30 | ); | ||
| 31 | |||
| 32 | 12 | has longitude => ( | |
| 33 | is => 'ro', | ||
| 34 | isa => Num, | ||
| 35 | predicate => 'has_longitude', | ||
| 36 | ); | ||
| 37 | |||
| 38 | 12 | has metro_code => ( | |
| 39 | is => 'ro', | ||
| 40 | isa => PositiveInt, | ||
| 41 | predicate => 'has_metro_code', | ||
| 42 | ); | ||
| 43 | |||
| 44 | 12 | has population_density => ( | |
| 45 | is => 'ro', | ||
| 46 | isa => NonNegativeInt, | ||
| 47 | predicate => 'has_population_density', | ||
| 48 | ); | ||
| 49 | |||
| 50 | 12 | has time_zone => ( | |
| 51 | is => 'ro', | ||
| 52 | isa => Str, | ||
| 53 | predicate => 'has_time_zone', | ||
| 54 | ); | ||
| 55 | |||
| 56 | 12 | 1; | |
| 57 | |||
| 58 | # ABSTRACT: Contains data for the location record associated with an IP address | ||
| 59 | |||
| 60 | __END__ | ||