From db2873926715568779820388052ffd80e5cb1963 Mon Sep 17 00:00:00 2001 From: MadWasp79 Date: Mon, 6 Apr 2020 15:12:29 +0300 Subject: [PATCH] debugging --- OsmAnd-java/src/main/java/net/osmand/NativeLibrary.java | 3 +-- .../net/osmand/binary/BinaryMapTransportReaderAdapter.java | 2 -- .../main/java/net/osmand/router/TransportRoutePlanner.java | 5 ++++- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/OsmAnd-java/src/main/java/net/osmand/NativeLibrary.java b/OsmAnd-java/src/main/java/net/osmand/NativeLibrary.java index d06886bd17..83277dd9ac 100644 --- a/OsmAnd-java/src/main/java/net/osmand/NativeLibrary.java +++ b/OsmAnd-java/src/main/java/net/osmand/NativeLibrary.java @@ -130,9 +130,8 @@ public class NativeLibrary { return closeBinaryMapFile(filePath); } -//todo public NativeTransportRoutingResult[] runNativePTRouting(int sx31, int sy31, int ex31, int ey31, - TransportRoutingConfiguration cfg, RouteCalculationProgress progress) { + TransportRoutingConfiguration cfg, RouteCalculationProgress progress) { return nativeTransportRouting(new int[] { sx31, sy31, ex31, ey31 }, cfg, progress); } diff --git a/OsmAnd-java/src/main/java/net/osmand/binary/BinaryMapTransportReaderAdapter.java b/OsmAnd-java/src/main/java/net/osmand/binary/BinaryMapTransportReaderAdapter.java index f857fac849..bf3a217306 100644 --- a/OsmAnd-java/src/main/java/net/osmand/binary/BinaryMapTransportReaderAdapter.java +++ b/OsmAnd-java/src/main/java/net/osmand/binary/BinaryMapTransportReaderAdapter.java @@ -635,6 +635,4 @@ public class BinaryMapTransportReaderAdapter { } } } - - } diff --git a/OsmAnd-java/src/main/java/net/osmand/router/TransportRoutePlanner.java b/OsmAnd-java/src/main/java/net/osmand/router/TransportRoutePlanner.java index b527170d8b..e845f7f024 100644 --- a/OsmAnd-java/src/main/java/net/osmand/router/TransportRoutePlanner.java +++ b/OsmAnd-java/src/main/java/net/osmand/router/TransportRoutePlanner.java @@ -43,7 +43,7 @@ public class TransportRoutePlanner { ctx.startCalcTime = System.currentTimeMillis(); List startStops = ctx.getTransportStops(start); List endStops = ctx.getTransportStops(end); - + /** delete */System.out.println(String.format("startStops/endStops: %d / %d", startStops.size(), endStops.size())); TLongObjectHashMap endSegments = new TLongObjectHashMap(); for(TransportRouteSegment s : endStops) { endSegments.put(s.getId(), s); @@ -57,8 +57,11 @@ public class TransportRoutePlanner { r.distFromStart = r.walkDist / ctx.cfg.walkSpeed; queue.add(r); } + + /** delete */System.out.println(String.format("queue size: %d", queue.size())); double finishTime = ctx.cfg.maxRouteTime; double maxTravelTimeCmpToWalk = MapUtils.getDistance(start, end) / ctx.cfg.walkSpeed - ctx.cfg.changeTime / 2; + /** delete */System.out.println(String.format("queue size: %d", queue.size())); List results = new ArrayList(); initProgressBar(ctx, start, end); while (!queue.isEmpty()) {