spatial4j.jar计算经纬度的Geohash值

引入jar包

<dependency>
  <groupId>org.locationtech.spatial4j</groupId>
  <artifactId>spatial4j</artifactId>
  <version>0.8</version>
</dependency>

用法示例

String geohash = GeohashUtils.encodeLatLon(116.20,39.56);