package Geo::Coder::DataScienceToolkit;
use strict;
use warnings;
use Carp;
use Encode;
use JSON;
use HTTP::Request;
use LWP::UserAgent;
use LWP::Protocol::http;
use URI;
=head1 NAME
Geo::Coder::D
= Encode::encode_utf8($location);
}
my $uri = URI->new("http://$self->{host}/maps/api/geocode/json");
$location =~ s/\s/+/g;
my %query_parameters = ('address' => $location, 'sensor' => 'false');
eturned error: on $url ", $res->status_line());
return { };
}
my $json = JSON->new()->utf8();
my $rc;
eval {
$rc = $json->decode($res->content());
};
if(!defined($rc)) {
if($@) {
Carp: