diff --git a/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/Label.java b/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/Label.java new file mode 100644 index 0000000..35a8df2 --- /dev/null +++ b/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/Label.java @@ -0,0 +1,37 @@ +package org.insa.graphs.algorithm.shortestpath; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collections; + +import org.insa.graphs.algorithm.AbstractSolution.Status; +import org.insa.graphs.model.Arc; +import org.insa.graphs.model.Graph; +import org.insa.graphs.model.Node; +import org.insa.graphs.model.Path; + + +public class Label { + + /* Sommet associé à ce label (sommet ou numéro de sommet) */ + Node sommetCourant ; + + /* Booléen vrai lorque le coût min de ce sommet est définitivement connu par l'algorithme */ + Boolean marque ; + + /* Valeur courante du plus court chemin depuis l'origine vers le sommet */ + double coutRealise ; + + /* correspond au sommet précédent sur le chemin correspondant au plus court chemin courant */ + Arc pere ; + +} + +public Label(Node sommetCourant, Boolean marque, int coutRealise, Arc pere) { + this.sommetCourant = sommetCourant ; + this.marque = marque ; + this.coutRealise = coutRealise ; + this.pere = pere ; +} + + diff --git a/be-graphes-model/src/main/java/org/insa/graphs/model/Path.java b/be-graphes-model/src/main/java/org/insa/graphs/model/Path.java index c52868e..4559902 100644 --- a/be-graphes-model/src/main/java/org/insa/graphs/model/Path.java +++ b/be-graphes-model/src/main/java/org/insa/graphs/model/Path.java @@ -30,7 +30,6 @@ public class Path { * @throws IllegalArgumentException If the list of nodes is not valid, i.e. two * consecutive nodes in the list are not connected in the graph. * - * @deprecated Need to be implemented. */ public static Path createFastestPathFromNodes(Graph graph, List nodes) throws IllegalArgumentException { @@ -86,7 +85,6 @@ public class Path { * @throws IllegalArgumentException If the list of nodes is not valid, i.e. two * consecutive nodes in the list are not connected in the graph. * - * @deprecated Need to be implemented. */ public static Path createShortestPathFromNodes(Graph graph, List nodes) throws IllegalArgumentException { @@ -267,7 +265,6 @@ public class Path { * * @return true if the path is valid, false otherwise. * - * @deprecated Need to be implemented. */ public boolean isValid() {