PHP Class KamranAhmed\Geocode\Geocode

Author: Kamran Ahmed ([email protected])
Afficher le fichier Open project: kamranahmedse/php-geocode

Méthodes publiques

Méthode Description
__construct ( string $key = '' ) Constructor
get ( $address ) : boolean | object Sends request to the passed Google Geocode API URL and fetches the address details and returns them
getServiceUrl ( ) : string Returns the private $serviceUrl

Method Details

__construct() public méthode

Constructor
public __construct ( string $key = '' )
$key string Google Maps Geocoding API key

get() public méthode

Sends request to the passed Google Geocode API URL and fetches the address details and returns them
public get ( $address ) : boolean | object
$address
Résultat boolean | object false if no data is returned by URL and the detail otherwise

getServiceUrl() public méthode

Returns the private $serviceUrl
public getServiceUrl ( ) : string
Résultat string The service URL