|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.ObjectJaCoP.set.search.MaxCardDiff<T>
T - type of variable being used in search.public class MaxCardDiff<T extends SetVar>
Defines a maximum cardinality difference variable comparator. The variable with the maximum difference in cardinality between the greatest lower bound and the least upper bound has the priority.
| Constructor Summary | |
|---|---|
MaxCardDiff()
It constructs a maximum cardinality difference variable comparator. |
|
| Method Summary | |
|---|---|
int |
compare(float left,
T var)
Compares the cardinality difference of the variable to the float value. |
int |
compare(T leftVar,
T rightVar)
Compares the cardinality difference of the variables. |
float |
metric(T var)
Returns the metric(Cardinality difference) of the variable. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MaxCardDiff()
| Method Detail |
|---|
public int compare(float left,
T var)
compare in interface ComparatorVariable<T extends SetVar>left - the baseline for comparison.var - variable which is compared to baseline.
public int compare(T leftVar,
T rightVar)
compare in interface ComparatorVariable<T extends SetVar>leftVar - left variablerightVar - right variable
public float metric(T var)
metric in interface ComparatorVariable<T extends SetVar>var - variable for which metric is computed.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||