Skip to content

Commit 209a1cb

Browse files
author
Peter
committed
improved incorrect javadoc of LocationIndex
1 parent ffa39cc commit 209a1cb

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

core/src/main/java/com/graphhopper/storage/index/LocationIndex.java

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,14 +47,18 @@ public interface LocationIndex extends Storable<LocationIndex>
4747
int findID( double lat, double lon );
4848

4949
/**
50+
* This method returns the closest QueryResult for the specified location (lat, lon) and only if
51+
* the filter accepts the edge as valid candidate (e.g. filtering away car-only results for bike
52+
* search)
53+
* <p>
5054
* @param edgeFilter if a graph supports multiple vehicles we have to make sure that the entry
5155
* node into the graph is accessible from a selected vehicle. E.g. if you have a FOOT-query do: <pre>
52-
* new DefaultEdgeFilter(new FootFlagEncoder());
56+
* new DefaultEdgeFilter(footFlagEncoder);
5357
* </pre>
5458
* <p>
5559
* @return An object containing the closest node and edge for the specfied location. The node id
56-
* has at least one edge which is accepted from the specified edgeFilter. If nothing is found it
57-
* returns null.
60+
* has at least one edge which is accepted from the specified edgeFilter. If nothing is found
61+
* the method QueryResult.isValid will return false.
5862
*/
5963
QueryResult findClosest( double lat, double lon, EdgeFilter edgeFilter );
6064

0 commit comments

Comments
 (0)