|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Defines the interface for a NeatSeeker search result weighter.
This interface defines the methods that a search result weighter must implement. Basically, a Weighter implements the Comparable interface and is capable of comparing Pointer objects based on statistical information.
Comparator
Method Summary | |
float |
calculateWeight(Pointer p)
Calculates the weight of a Pointer. |
int |
compare(java.lang.Object o1,
java.lang.Object o2)
Compares two Pointers for relevance. |
void |
init(Repository r,
Statistics s)
Initialises the Weighter with the given Repository and given Statistics. |
void |
setResultCount(int c)
Sets the number of results returned by a query. |
java.lang.String |
toString()
Returns a textual identification of this Weighter. |
Methods inherited from interface java.util.Comparator |
equals |
Method Detail |
public void init(Repository r, Statistics s)
public int compare(java.lang.Object o1, java.lang.Object o2)
Implemeting classes should throw a RuntimeException if the object are not members of the Pointer class.
compare
in interface java.util.Comparator
public void setResultCount(int c)
public float calculateWeight(Pointer p)
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |