LocationUtils { static boolean isInside(LocationUSourceData data, Location location) { for (LatLong center : data.locations) { if (inside(center, data.radius, location.getLatitude(), location.getLongitude())) { return true; } } return false; }   static final int METERS_PER_DEGREE; }
@Test public void testIsInside() throws ParseException { Assert.assertTrue( LocationUtils.inside(LatLong.fromString("50, 50"), 150000, LatLong.fromString("50, 51")) ); Assert.assertFalse( LocationUtils.inside(LatLong.fromString("50, 50"), 100000, LatLong.fromString("50, 51")) ); }