### Question:
GeoFenceUtil { public static String geofenceString(final double latitude, final double longitude, String geometryWKT) { return geofenceStringImpl(latitude, longitude, geometryWKT); }  static boolean geofence(final double latitude, final double longitude, String geometryWKT); static String geofenceString(final double latitude, final double longitude, String geometryWKT); static String geofence(final double latitude, final double longitude, final String statusBefore, String geometryWKT); static List<String> geofence(final double latitude, final double longitude, List<String> idGeometryListWKT); static List<String> geofence(final double latitude, final double longitude, List<String> geometryListId, List<String> geometryListWKT);  }### Answer:
@Test public void test() throws ParseException { LineString route = (LineString)reader.read(ROUTE_WKT); for (Coordinate coord : route.getCoordinates()) { System.out.println(coord.x + ":" + coord.y); if (GeoFenceUtil.geofenceString(coord.y, coord.x, COLUMBIA_WKT).equals("INSIDE")) { System.out.println("INSIDE"); } } }
@Test public void testWithDistance() throws ParseException, TransformException { LineString route = (LineString)reader.read(ROUTE_WKT); Polygon columbiaWkt = (Polygon) reader.read(COLUMBIA_WKT); for (Coordinate coord : route.getCoordinates()) { String status = GeoFenceUtil.geofenceString(coord.y, coord.x, COLUMBIA_WKT); double distance = DistanceUtil.calculateDistanceToPolygon( geometryFactory.createPoint(new Coordinate(coord.x, coord.y)), columbiaWkt); System.out.printf("%-20s %f %n", status, distance); } }