use of com.graphhopper.api.model.GHGeocodingEntry in project graphhopper by graphhopper.
the class GraphHopperGeocodingIT method testReverseGeocoding.
@Test
public void testReverseGeocoding() {
GHGeocodingResponse response = geocoding.geocode(new GHGeocodingRequest(52.5170365, 13.3888599, "en", 5));
assertEquals(5, response.getHits().size());
GHGeocodingEntry entry = response.getHits().get(0);
assertTrue(entry.getName().contains("Berlin"));
assertEquals("place", entry.getOsmKey());
assertEquals(0, entry.getExtent().length);
}
Aggregations