This commit is contained in:
Victor Shcherb 2020-03-18 16:33:46 +01:00
parent f9fe588c10
commit c7bbb80213

View file

@ -201,9 +201,13 @@ public class RouteSegmentResult implements StringExternalizable<RouteDataBundle>
bundle.putArray("types", convertTypes(object.types, rules));
int start = Math.min(startPointIndex, endPointIndex);
int end = Math.max(startPointIndex, endPointIndex);
bundle.putArray("pointTypes", convertTypes(Arrays.copyOfRange(object.pointTypes, start,
Math.min(end + 1, object.pointTypes.length)), rules));
bundle.putArray("names", convertNameIds(object.nameIds, rules));
if (object.hasPointTypes()) {
bundle.putArray("pointTypes", convertTypes(
Arrays.copyOfRange(object.pointTypes, start, Math.min(end + 1, object.pointTypes.length)), rules));
}
if (object.hasPointNames()) {
bundle.putArray("names", convertNameIds(object.nameIds, rules));
}
}
@Override