net.sourceforge.jsl
Class AbstractScoringSearch
java.lang.Object
|
+--net.sourceforge.jsl.AbstractOpenClosedListSearch
|
+--net.sourceforge.jsl.AbstractScoringSearch
- All Implemented Interfaces:
- ScoringSearch, Search
- Direct Known Subclasses:
- AStarSearch
- public abstract class AbstractScoringSearch
- extends AbstractOpenClosedListSearch
- implements ScoringSearch
Abstract base class for a scoring search. Open list will be sorted accoring to score calculated
for each node in the list. As an extension if two nodes have equal score the one having less current costs
will be preferred.
Fields inherited from class net.sourceforge.jsl.AbstractOpenClosedListSearch |
closedList, closeGoal, expandCnt, expandGoal, maxClosed, maxDepth, maxExpands, maxOpen, openList, seed, useHashSet |
Methods inherited from class net.sourceforge.jsl.AbstractOpenClosedListSearch |
checkForEmergencyStop, cutOff, expand, getClosedList, getCloseGoal, getExpandGoal, getMaxClosed, getMaxDepth, getMaxExpands, getMaxOpen, getOpenList, search, search, setCloseGoal, setExpandGoal, setMaxClosed, setMaxDepth, setMaxExpands, setMaxOpen, setSeed, setUseHashSet |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractScoringSearch
public AbstractScoringSearch()
score
public abstract double score(SearchNode node)
- Description copied from interface:
ScoringSearch
- Calculates the score of the given node. The score indicates the preference for the expansion
of a specidic node, the lower the score, the better.
- Specified by:
score
in interface ScoringSearch
- Parameters:
node
- the node to calculate the score for
- Returns:
- the score for the node in double precision
writeStates
protected void writeStates(Collection states)
- Specified by:
writeStates
in class AbstractOpenClosedListSearch
writeState
protected void writeState(SearchNode state)
- Specified by:
writeState
in class AbstractOpenClosedListSearch
sortList
protected void sortList()
Copyright © 2003-2004 Henrik Heine, Oliver Zeigermann. All Rights Reserved.