blib/lib/Geo/Coder/Google.pm | |||
---|---|---|---|
Criterion | Covered | Total | % |
statement | 12 | 12 | 100.0 |
branch | 1 | 2 | 50.0 |
condition | 1 | 2 | 50.0 |
subroutine | 3 | 3 | 100.0 |
pod | 0 | 1 | 0.0 |
total | 17 | 20 | 85.0 |
line | stmt | bran | cond | sub | pod | time | code |
---|---|---|---|---|---|---|---|
1 | package Geo::Coder::Google; | ||||||
2 | |||||||
3 | 3 | 3 | 205649 | use strict; | |||
3 | 27 | ||||||
3 | 98 | ||||||
4 | 3 | 3 | 18 | use warnings; | |||
3 | 6 | ||||||
3 | 378 | ||||||
5 | our $VERSION = '0.19'; | ||||||
6 | |||||||
7 | sub new { | ||||||
8 | 7 | 7 | 0 | 3682 | my ($self, %param) = @_; | ||
9 | 7 | 50 | 25 | my $apiver = delete $param{apiver} || 3; | |||
10 | 7 | 18 | my $class = 'Geo::Coder::Google::V' . $apiver; | ||||
11 | |||||||
12 | 7 | 50 | 331 | eval "require $class"; die $@ if $@; | |||
7 | 30 | ||||||
13 | 7 | 30 | $class->new(%param); | ||||
14 | } | ||||||
15 | |||||||
16 | 1; | ||||||
17 | __END__ |