no.sesat.search.query.token
Class FastQueryMatchingEvaluatorFactory

java.lang.Object
  extended by no.sesat.search.query.token.AbstractEvaluatorFactory
      extended by no.sesat.search.query.token.FastQueryMatchingEvaluatorFactory

public final class FastQueryMatchingEvaluatorFactory
extends AbstractEvaluatorFactory

Responsible for loading and serving the VeryFast (Fast Query Matching) Token Evaluator. One VeryFastTokenEvaluator is constructed per query and used for all tokens of type FAST.

Version:
$Id: FastQueryMatchingEvaluatorFactory.java 7225 2009-04-09 00:32:20Z ssmiweve $

Nested Class Summary
 
Nested classes/interfaces inherited from class no.sesat.search.query.token.AbstractEvaluatorFactory
AbstractEvaluatorFactory.Context
 
Constructor Summary
FastQueryMatchingEvaluatorFactory(AbstractEvaluatorFactory.Context cxt)
           
 
Method Summary
 TokenEvaluator getEvaluator(TokenPredicate token)
          If the evaluator is not found in this site it will fallback and look in the parent site.
 boolean isResponsibleFor(TokenPredicate token)
          Is the factory responsibe for evaluation of this TokenPredicate.
 
Methods inherited from class no.sesat.search.query.token.AbstractEvaluatorFactory
getContext, instanceOf
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FastQueryMatchingEvaluatorFactory

public FastQueryMatchingEvaluatorFactory(AbstractEvaluatorFactory.Context cxt)
                                  throws SiteKeyedFactoryInstantiationException
Throws:
SiteKeyedFactoryInstantiationException
Method Detail

getEvaluator

public TokenEvaluator getEvaluator(TokenPredicate token)
                            throws EvaluationException
Description copied from class: AbstractEvaluatorFactory
If the evaluator is not found in this site it will fallback and look in the parent site.

Specified by:
getEvaluator in class AbstractEvaluatorFactory
Parameters:
token - the predicate the evaluator is to be used for
Returns:
the TokenEvaluator to use. Or TokenEvaluationEngineImpl.ALWAYS_FALSE_EVALUATOR if not found.
Throws:
EvaluationException

isResponsibleFor

public boolean isResponsibleFor(TokenPredicate token)
Description copied from class: AbstractEvaluatorFactory
Is the factory responsibe for evaluation of this TokenPredicate. Default implementation checks that getEvaluator(..) does not return ALWAYS_FALSE_EVALUATOR

Overrides:
isResponsibleFor in class AbstractEvaluatorFactory
Parameters:
token - the TokenPredicate we're checking
Returns:
true if factory is responsible for evaluating the given TokenPredicate.


Copyright © 2005-2009 Schibsted ASA. All Rights Reserved.