added startway check
This commit is contained in:
parent
6b4d989868
commit
d2d639666e
8 changed files with 64 additions and 5 deletions
|
|
@ -161,7 +161,8 @@ public final class MicroCache2 extends MicroCache {
|
|||
int ilontarget = ilon + dlon_remaining;
|
||||
int ilattarget = ilat + dlat_remaining;
|
||||
if (matcher != null) {
|
||||
if (!matcher.start(ilon, ilat, ilontarget, ilattarget)) {
|
||||
boolean useAsStartWay = wayValidator.checkStartWay(wayTags.data);
|
||||
if (!matcher.start(ilon, ilat, ilontarget, ilattarget, useAsStartWay)) {
|
||||
matcher = null;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -13,4 +13,6 @@ public interface TagValueValidator {
|
|||
boolean isLookupIdxUsed(int idx);
|
||||
|
||||
void setDecodeForbidden(boolean decodeForbidden);
|
||||
|
||||
boolean checkStartWay(byte[] ab);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ package btools.codec;
|
|||
* matches to the waypoints
|
||||
*/
|
||||
public interface WaypointMatcher {
|
||||
boolean start(int ilonStart, int ilatStart, int ilonTarget, int ilatTarget);
|
||||
boolean start(int ilonStart, int ilatStart, int ilonTarget, int ilatTarget, boolean useAsStartWay);
|
||||
|
||||
void transferNode(int ilon, int ilat);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue