public function GeocoderInterface::reverseGeocode in Geolocation Field 8.2
Same name and namespace in other branches
- 8.3 src/GeocoderInterface.php \Drupal\geolocation\GeocoderInterface::reverseGeocode()
Reverse geocode an address.
Intended return subject to available data:
[
'organization' => '',
'address_line1' => '',
'address_line2' => '',
'postal_code' => '',
'sorting_code' => '',
'dependent_locality' => [],
'locality' => [],
'administrative_area' => [],
'country' => [],
'formatted_address' => '',
];
Parameters
float $latitude: Latitude to reverse geocode.
float $longitude: Longitude to reverse geocode.
Return value
array||null Address or NULL.
1 method overrides GeocoderInterface::reverseGeocode()
- GeocoderBase::reverseGeocode in src/
GeocoderBase.php - Reverse geocode an address.
File
- src/
GeocoderInterface.php, line 84
Class
- GeocoderInterface
- Defines an interface for geolocation geocoder plugins.
Namespace
Drupal\geolocationCode
public function reverseGeocode($latitude, $longitude);