private static class JavaClassDefinition.FuzzyMatch extends JavaClassDefinition.MethodMatch implements java.lang.Comparable<JavaClassDefinition.FuzzyMatch>
Modifier and Type | Field and Description |
---|---|
private int |
exact
Number of exact matches.
|
private int |
near
Number of "near" type equivalent matches.
|
private static int |
next
Source for each instance's unique ordinal, constantly growing over time.
|
private int |
ordinal
Unique fallback value to force ordering based on construction order.
|
private int |
parent
Number of parent matches.
|
private int |
unwrap
Number of object unwrapping matches.
|
cvt, method
Constructor and Description |
---|
FuzzyMatch(java.lang.reflect.Executable method,
int exact,
int unwrap,
int near,
int parent,
java.lang.Class<?>[] cvt)
Construct an instance.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(JavaClassDefinition.FuzzyMatch other)
Compares this instance with the given instance for purposes of sorting.
|
boolean |
isExact()
Report if this is or is not an exact match.
|
private static int next
private int exact
private int unwrap
private int near
private int parent
private int ordinal
public FuzzyMatch(java.lang.reflect.Executable method, int exact, int unwrap, int near, int parent, java.lang.Class<?>[] cvt)
method
- The method or c'tor being matched.exact
- The number of exact matches.unwrap
- The number of object unwrap matches.near
- The number of near type equivalents.parent
- The number of parent matches.cvt
- The parameters that need to be converted/wrapped.public boolean isExact()
isExact
in class JavaClassDefinition.MethodMatch
false
.public int compareTo(JavaClassDefinition.FuzzyMatch other)
The precedence order (higher precedence sorts first):
compareTo
in interface java.lang.Comparable<JavaClassDefinition.FuzzyMatch>
other
- The instance being compared to the "this" instance.