Package mazealgo.model.algorithms.search
Class Solution
java.lang.Object
mazealgo.model.algorithms.search.Solution
- All Implemented Interfaces:
Serializable
The path returned by a search algorithm: an ordered list of states
from start to goal (inclusive). Built by walking
cameFrom
from the goal back to the start, then reversing.
Carries the number of nodes the producing algorithm evaluated so
the UI can keep its "Nodes: N" counter accurate even when the solve
happened on the server (the count survives the
ObjectOutputStream roundtrip).
Once constructed, the Solution is fully self-contained — it holds its own list of states and no longer depends on the search algorithm or the visited set.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
Solution
-
-
Method Details
-
getSolutionPath
-
getNodesEvaluated
public int getNodesEvaluated() -
setNodesEvaluated
public void setNodesEvaluated(int nodesEvaluated)
-