Skip to content

Simple library function which takes district and lat/lng as parameter and tells if that lat/lng is present in that district or not

Notifications You must be signed in to change notification settings

Mukund2900/indian-district-geocode-checker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 

Repository files navigation

Use this function, specify your district and lat lng ->

cities.geojson is a file with all districts and their multipolygon ( ref -> https://www.kaggle.com/datasets/adityaradha007/indian-districts-geojson?resource=download )

public static void main(String[] args) {
    CityChecker cityChecker = new CityChecker("cities.geojson"); //refer according to your path
    boolean isWithinCity = cityChecker.isCoordinateInCity("Bangalore", 12.9716, 77.5946);
    System.out.println("Coordinate is within city: " + isWithinCity);
}

About

Simple library function which takes district and lat/lng as parameter and tells if that lat/lng is present in that district or not

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages