Class SMICRanking
- All Implemented Interfaces:
Comparator<SMICState>,StateRanking<SMICState>
SMICRanking class defines a heuristic ranking criterion for comparing two SMICState instances during search or optimization.
It implements the StateRanking interface, which is used by decision diagram
optimization (DDO) solvers or search algorithms to determine the relative quality or priority of
explored states.
In this implementation, the ranking is based solely on the currentTime attribute of
the state — that is, the state with the smaller current time is considered better (ranked
higher), since it represents a schedule that reaches an earlier point in time.
This ranking can be used, for example, to expand partial schedules that have progressed less in time before others, potentially leading to better exploration efficiency in time-sensitive scheduling problems.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Constructor Details
-
SMICRanking
public SMICRanking()Creates a new instance of this ranking.
-
-
Method Details
-
compare
Compares twoSMICStateinstances based on their current time.The comparison is ascending: a state with a smaller
currentTimeis considered "better" or of higher priority.- Specified by:
comparein interfaceComparator<SMICState>- Parameters:
o1- the first state to compareo2- the second state to compare- Returns:
- a negative integer if
o1has a smaller current time thano2, zero if they are equal, or a positive integer otherwise
-