[ Version ( since = "3.12" ) ]
public Location find_nearest_city (double lat, double lon)
Finds the nearest city to the passed latitude and longitude, among the descendants of this.
this must be at most a gweather_location_adm1 location. This restriction may be lifted in a future version.
Note that this function does not check if (lat
, lon
) fall inside this, or are
in the same region and timezone as the return value.
this |
The parent location, which will be searched recursively |
lat |
Latitude, in degrees |
lon |
Longitude, in degrees |
the city closest to ( |