-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
When building a reverse search URL, try both OSM types "W" and "N"
Constructing a Nominatim reverse search URL requires both, OSM Id and OSM type. The first try is done using OSM Type "W" (way), the second try with OSM Type "N" (node). References #14490
- Loading branch information
Showing
5 changed files
with
85 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
src/main/java/net/contargo/iris/address/nominatim/service/OsmType.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
package net.contargo.iris.address.nominatim.service; | ||
|
||
/** | ||
* @author Oliver Messner - [email protected] | ||
*/ | ||
enum OsmType { | ||
|
||
WAY { | ||
|
||
@Override | ||
String getKey() { | ||
|
||
return "W"; | ||
} | ||
}, | ||
|
||
NODE { | ||
|
||
@Override | ||
String getKey() { | ||
|
||
return "N"; | ||
} | ||
}; | ||
|
||
abstract String getKey(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters