From 7640fa34c75f08634b1ad9767866069bbd2c219a Mon Sep 17 00:00:00 2001 From: Holt59 Date: Sat, 24 Feb 2018 20:55:23 +0100 Subject: [PATCH] Switch to static methods for creating paths from nodes. --- src/main/org/insa/graph/io/BinaryPathReader.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/main/org/insa/graph/io/BinaryPathReader.java b/src/main/org/insa/graph/io/BinaryPathReader.java index d3af795..8b5787c 100644 --- a/src/main/org/insa/graph/io/BinaryPathReader.java +++ b/src/main/org/insa/graph/io/BinaryPathReader.java @@ -7,7 +7,6 @@ import java.util.ArrayList; import org.insa.graph.Graph; import org.insa.graph.Node; import org.insa.graph.Path; -import org.insa.graph.Path.CreationMode; public class BinaryPathReader extends BinaryReader implements PathReader { @@ -46,7 +45,7 @@ public class BinaryPathReader extends BinaryReader implements PathReader { nodes.add(readNode(graph)); } - return new Path(graph, nodes, CreationMode.SHORTEST_TIME); + return Path.createFastestPathFromNodes(graph, nodes); } /**