PHP Class Geocoder\Provider\GoogleMaps

Author: William Durand ([email protected])
Inheritance: extends AbstractHttpProvider, implements Geocoder\Provider\LocaleAwareProvider, use trait Geocoder\Provider\LocaleTrait
Afficher le fichier Open project: willdurand/geocoder Class Usage Examples

Méthodes publiques

Méthode Description
__construct ( Http\Client\HttpClient $client, string $locale = null, string $region = null, boolean $useSsl = false, string $apiKey = null )
business ( Http\Client\HttpClient $client, string $clientId, string $privateKey = null, string $locale = null, string $region = null, boolean $useSsl = false, string $apiKey = null ) : GoogleMaps Google Maps for Business https://developers.google.com/maps/documentation/business/
geocode ( $address ) {@inheritDoc}
getName ( ) {@inheritDoc}
reverse ( $latitude, $longitude ) {@inheritDoc}
setRegion ( $region )

Private Methods

Méthode Description
buildQuery ( string $query ) : string
executeQuery ( string $query )
signQuery ( string $query ) : string Sign a URL with a given crypto key Note that this URL must be properly URL-encoded src: http://gmaps-samples.googlecode.com/svn/trunk/urlsigning/UrlSigner.php-source
updateAddressComponent ( array &$resultSet, string $type, object $values ) : array Update current resultSet with given key/value.

Method Details

__construct() public méthode

public __construct ( Http\Client\HttpClient $client, string $locale = null, string $region = null, boolean $useSsl = false, string $apiKey = null )
$client Http\Client\HttpClient An HTTP adapter
$locale string A locale (optional)
$region string Region biasing (optional)
$useSsl boolean Whether to use an SSL connection (optional)
$apiKey string Google Geocoding API key (optional)

business() public static méthode

Google Maps for Business https://developers.google.com/maps/documentation/business/
public static business ( Http\Client\HttpClient $client, string $clientId, string $privateKey = null, string $locale = null, string $region = null, boolean $useSsl = false, string $apiKey = null ) : GoogleMaps
$client Http\Client\HttpClient An HTTP adapter
$clientId string Your Client ID
$privateKey string Your Private Key (optional)
$locale string A locale (optional)
$region string Region biasing (optional)
$useSsl boolean Whether to use an SSL connection (optional)
$apiKey string Google Geocoding API key (optional)
Résultat GoogleMaps

geocode() public méthode

{@inheritDoc}
public geocode ( $address )

getName() public méthode

{@inheritDoc}
public getName ( )

reverse() public méthode

{@inheritDoc}
public reverse ( $latitude, $longitude )

setRegion() public méthode

public setRegion ( $region )