diff --git a/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/DijkstraAlgorithm.java b/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/DijkstraAlgorithm.java index 61f3028..365a856 100644 --- a/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/DijkstraAlgorithm.java +++ b/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/DijkstraAlgorithm.java @@ -1,109 +1,124 @@ -package org.insa.graphs.algorithm.shortestpath; - -import org.insa.graphs.algorithm.AbstractSolution.Status; -import org.insa.graphs.algorithm.utils.BinaryHeap; -import org.insa.graphs.model.Arc; -import org.insa.graphs.model.Node; -import org.insa.graphs.model.Path; -import java.util.ArrayList; -import java.util.Collections;//trier tout ça - -public class DijkstraAlgorithm extends ShortestPathAlgorithm { + package org.insa.graphs.algorithm.shortestpath; - - public DijkstraAlgorithm(ShortestPathData data) { - super(data); - } - - public Label LabelTyped(Node sommet,Arc padre, float prix){ - return new Label(sommet,padre, prix); - } - - @Override - protected ShortestPathSolution doRun() { - - final ShortestPathData data = getInputData(); - ShortestPathSolution solution = new ShortestPathSolution(data,Status.UNKNOWN);//modifié - - //initialisation - BinaryHeap