|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.terrier.matching.dsms.BooleanScoreModifier
public class BooleanScoreModifier
If not all the query terms appear in a document, then this modifier zeros the document's score.
Field Summary | |
---|---|
protected static org.apache.log4j.Logger |
logger
the logger for this class |
protected java.util.ArrayList<Query> |
terms
The terms to check. |
Constructor Summary | |
---|---|
BooleanScoreModifier()
An empty default constructor. |
|
BooleanScoreModifier(java.util.ArrayList<Query> ts)
A constructor where we specify which of the query terms should exist in the documents. |
Method Summary | |
---|---|
java.lang.Object |
clone()
Clone this DSM. |
java.lang.String |
getName()
Returns the name of the document score modifier. |
boolean |
modifyScores(Index index,
MatchingQueryTerms query,
ResultSet resultSet)
Zeros the scores of documents in which only some of the query terms appear. |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final org.apache.log4j.Logger logger
protected java.util.ArrayList<Query> terms
Constructor Detail |
---|
public BooleanScoreModifier()
public BooleanScoreModifier(java.util.ArrayList<Query> ts)
ts
- ArrayList the query terms that should
appear in the retrieved documents after
applying this modifier.Method Detail |
---|
public java.lang.String getName()
getName
in interface DocumentScoreModifier
public boolean modifyScores(Index index, MatchingQueryTerms query, ResultSet resultSet)
modifyScores
in interface DocumentScoreModifier
index
- Index the data structures used for retrieval.query
- TermTreeNode[] the array of the query terms.resultSet
- ResultSet the set of retrieved documents.
public java.lang.Object clone()
clone
in interface DocumentScoreModifier
clone
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |