Fix #5003
This commit is contained in:
parent
d902888f4a
commit
f8246c5cf4
2 changed files with 16 additions and 0 deletions
|
@ -237,6 +237,7 @@ public class RouteDataObject {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public String getName(String lang){
|
public String getName(String lang){
|
||||||
return getName(lang, false);
|
return getName(lang, false);
|
||||||
}
|
}
|
||||||
|
@ -685,6 +686,18 @@ public class RouteDataObject {
|
||||||
return direction;
|
return direction;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean isRoadDeleted() {
|
||||||
|
int[] pt = getTypes();
|
||||||
|
int sz = pt.length;
|
||||||
|
for (int i = 0; i < sz; i++) {
|
||||||
|
RouteTypeRule r = region.quickGetEncodingRule(pt[i]);
|
||||||
|
if ("osmand_change".equals(r.getTag()) && "delete".equals(r.getValue())) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
public boolean isStopApplicable(boolean direction, int intId, int startPointInd, int endPointInd) {
|
public boolean isStopApplicable(boolean direction, int intId, int startPointInd, int endPointInd) {
|
||||||
int[] pt = getPointTypes(intId);
|
int[] pt = getPointTypes(intId);
|
||||||
int sz = pt.length;
|
int sz = pt.length;
|
||||||
|
|
|
@ -71,6 +71,9 @@ public class RouteSegmentResult {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void attachRoute(int roadIndex, RouteSegmentResult r){
|
public void attachRoute(int roadIndex, RouteSegmentResult r){
|
||||||
|
if(r.getObject().isRoadDeleted()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
int st = Math.abs(roadIndex - startPointIndex);
|
int st = Math.abs(roadIndex - startPointIndex);
|
||||||
if(attachedRoutes[st] == null) {
|
if(attachedRoutes[st] == null) {
|
||||||
attachedRoutes[st] = new ArrayList<RouteSegmentResult>();
|
attachedRoutes[st] = new ArrayList<RouteSegmentResult>();
|
||||||
|
|
Loading…
Reference in a new issue