Terrier IR Platform
2.2.1

uk.ac.gla.terrier.matching.dsms
Class BooleanFallback

java.lang.Object
  extended by uk.ac.gla.terrier.matching.dsms.BooleanFallback
All Implemented Interfaces:
java.lang.Cloneable, DocumentScoreModifier

public class BooleanFallback
extends java.lang.Object
implements DocumentScoreModifier

This class provides a boolean fallback document score modifier for matching. In other words, if there any of the retrieved documents contain all undecorated query terms (ie query terms without any operators), then we remove from the result set documents that do not contain all undecorated query terms. Otherwise, we do nothing.

Version:
$Revision: 1.11 $
Author:
Vassilis Plachouras & Craig Macdonald

Constructor Summary
BooleanFallback()
           
 
Method Summary
 java.lang.Object clone()
           
 java.lang.String getName()
          Returns the name of the modifier, which is BooleanFallback.
 boolean modifyScores(Index index, MatchingQueryTerms queryTerms, ResultSet resultSet)
          Applies boolean fallback to the given result set.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BooleanFallback

public BooleanFallback()
Method Detail

modifyScores

public boolean modifyScores(Index index,
                            MatchingQueryTerms queryTerms,
                            ResultSet resultSet)
Applies boolean fallback to the given result set.

Specified by:
modifyScores in interface DocumentScoreModifier
Parameters:
index - The data structures used for retrieval.
queryTerms - the terms of the query.
resultSet - the set of retrieved documents for the query.
Returns:
true if any scores have been altered

getName

public java.lang.String getName()
Returns the name of the modifier, which is BooleanFallback.

Specified by:
getName in interface DocumentScoreModifier
Returns:
the name of the modifier.

clone

public java.lang.Object clone()
Specified by:
clone in interface DocumentScoreModifier
Overrides:
clone in class java.lang.Object

Terrier IR Platform
2.2.1

Terrier Information Retrieval Platform 2.2.1. Copyright 2004-2008 University of Glasgow