Branch Coverage

File:blib/lib/Geo/Coder/Free.pm
Coverage:77.0%

line%coveragebranch
299100TFif (not defined $class) { }
100TFelsif (&Scalar::Util::blessed($class)) { }
300100TFif (keys %{$params;})
313100TFunless ($alternatives)
31650TFif $line =~ /^\s*(#|$)/
31850TFunless defined $to
32050TFif length $from and length $to
325100TFif (not defined $$params{"openaddr"} and $ENV{"OPENADDR_HOME"})
337100TFif ($$params{"openaddr"})
340100TFif (my $cache = $$params{"cache"})
407100TFif (ref $self) { }
100TFelsif (@_) { }
50TFelsif (defined $self and $self ne __PACKAGE__) { }
415100TF_valid_location($location) ? :
532100TFif (not ref $self) { }
100TFelsif (ref $self eq 'HASH') { }
533100TFif (scalar @_) { }
100TFelsif (not defined $self) { }
100TFelsif ($self eq __PACKAGE__) { }
554100TFunless $on_error eq "croak" or $on_error eq "undef"
561100TFif (defined $params{"location"} and not _valid_location($params{"location"}))
562100TFif not length $params{"location"} or $on_error eq "undef"
565100TFif (defined $params{"scantext"} and not _valid_location($params{"scantext"}))
566100TFif not length $params{"scantext"} or $on_error eq "undef"
570100TFif ($$self{"openaddr"})
571100TFif (my $scantext = $params{"scantext"})
572100TFif $$self{"scantext_misses"}{$scantext}
58150TFif @direct
590100TFif (my $iw = $params{'ignore_words'}) { }
60150TFif (@{$res;})
6020TFwantarray ? :
60850TFif (@{$res;})
6090TFwantarray ? :
6180TFif defined $_
62050TFif (@{$res;})
6210TFwantarray ? :
62550TFif ($region)
6270TFif ($region eq 'GB') { }
0TFelsif ($region eq 'US') { }
0TFelsif ($region eq 'Canada') { }
6310TFif (@candidates)
6340TFif $$ignore_words{lc $candidate}
6370TFif @hits
6390TFif @regional
648100TFif (wantarray) { }
65050TFif @rc and $rc[0]
6530TFif @rc and $rc[0]
655100TFif (my $rc = $$self{"openaddr"}->geocode(\%params))
659100TFif (my $rc = $$self{"local"}->geocode(\%params))
66950TFif (my $alt = $$self{"alternatives"})
675100TFif $_alternatives_active{$key}
677100TFunless $location =~ /$key/
681100TFif (my $rc = $self->geocode(\%params))
685100TFif ($value =~ /, /)
68950TFif (my $rc = $self->geocode(\%params))
704100TFif ($params{"location"})
708100TFunless $params{"scantext"}
866100TFunless (&Scalar::Util::blessed($self))
867100TFif ref $self eq "ARRAY"
869100TFunless @_
874100TFunless ref $values eq "ARRAY"
87950TFif (@_ == 1 and ref $_[0] eq 'HASH') { }
100TFelsif (scalar(@_) % 2 == 0 and not grep({ref $_;} @_)) { }
888100TFunless $on_error eq "croak" or $on_error eq "undef"
898100TFdefined $value ? :
899100TFif $reserved{$key}
912100TFdefined $value ? :
913100TFif $seen{$key}++
925100TFdefined $region ? :
935100TFunless $reads > 0
942100TFif _valid_location($key) and $read
945100TFif (defined $point) { }
976100TFunless my $backend = $$self{$slot}
97750TFunless &Scalar::Util::blessed($backend) and $backend->can("reads")
1017100TF@_ > 1 ? :
1086100TFwantarray ? :
50TFunless defined $point and ref $point and (&Scalar::Util::reftype($point) || '') eq "HASH"
1091100TFif defined $backend
1100100TFwantarray ? :
1136100TFif (not ref $self) { }
50TFelsif (ref $self eq 'HASH') { }
1137100TFif (scalar @_) { }
100TFelsif (not defined $self) { }
100TFelsif ($self eq __PACKAGE__) { }
115350TFif ($$self{"openaddr"})
1156100TFif ($params{"latlng"})
12180TF$ENV{'OPENADDR_HOME'} ? :
12210TFunless @rc
1243100TF@args ? :
1256100TFif ref $args[0] eq "HASH"
1257100TFif ref $args[0]
1258100TFif @args and @args % 2 == 0
1259100TFif @args == 1
1263100TFif @args
1281100TF$region ? :
1282100TFif $$self{"scantext_misses"}{$location}
1284100TFif (@res) { }
1314100TFif not $$stop{lc $_}