### Question:
Isochrone extends AbstractRoutingAlgorithm { public void search(int from, final Callback callback) { searchInternal(from); final NodeAccess na = graph.getNodeAccess(); fromMap.forEach(new IntObjectProcedure<IsoLabel>() { @Override public void apply(int nodeId, IsoLabel label) { double lat = na.getLatitude(nodeId); double lon = na.getLongitude(nodeId); IsoLabelWithCoordinates isoLabelWC = new IsoLabelWithCoordinates(nodeId); isoLabelWC.coordinate = new GHPoint(lat, lon); isoLabelWC.timeMillis = Math.round(label.time); isoLabelWC.distance = (int) Math.round(label.distance); isoLabelWC.edgeId = label.edge; if (label.parent != null) { IsoLabel prevLabel = (IsoLabel) label.parent; nodeId = prevLabel.adjNode; double prevLat = na.getLatitude(nodeId); double prevLon = na.getLongitude(nodeId); isoLabelWC.prevNodeId = nodeId; isoLabelWC.prevEdgeId = prevLabel.edge; isoLabelWC.prevCoordinate = new GHPoint(prevLat, prevLon); isoLabelWC.prevDistance = (int) Math.round(prevLabel.distance); isoLabelWC.prevTimeMillis = Math.round(prevLabel.time); } callback.add(isoLabelWC); } }); } Isochrone(Graph g, Weighting weighting, boolean reverseFlow); @Override Path calcPath(int from, int to); void setTimeLimit(double limit); void setDistanceLimit(double limit); void search(int from, final Callback callback); List<List<Coordinate>> searchGPS(int from, final int bucketCount); List<Set<Integer>> search(int from, final int bucketCount); @Override String getName(); @Override int getVisitedNodes();  }### Answer:
@Test public void testSearch() { initDirectedAndDiffSpeed(graph); PMap pMap = new PMap(); Isochrone instance = new Isochrone(graph, new FastestWeighting(carEncoder, pMap), false); instance.setTimeLimit(60); List<Set<Integer>> res = instance.search(0, 5); assertEquals("[[0, 4], [6], [1, 7], [5], [2, 3]]", res.toString()); instance = new Isochrone(graph, new FastestWeighting(carEncoder, pMap), false); instance.setTimeLimit(30); res = instance.search(0, 5); assertEquals("[[0], [4], [], [6], [1, 7]]", res.toString()); }