org.apache.lucene.benchmark.quality.utils
Class SimpleQQParser

java.lang.Object
  extended by org.apache.lucene.benchmark.quality.utils.SimpleQQParser
All Implemented Interfaces:
QualityQueryParser

public class SimpleQQParser
extends Object
implements QualityQueryParser

Simplistic quality query parser. A Lucene query is created by passing the value of the specified QualityQuery name-value pair(s) into a Lucene's QueryParser using StandardAnalyzer.


Constructor Summary
SimpleQQParser(String[] qqNames, String indexField)
          Constructor of a simple qq parser.
SimpleQQParser(String qqName, String indexField)
          Constructor of a simple qq parser.
 
Method Summary
 Query parse(QualityQuery qq)
          Parse a given QualityQuery into a Lucene query.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleQQParser

public SimpleQQParser(String[] qqNames,
                      String indexField)
Constructor of a simple qq parser.

Parameters:
qqNames - name-value pairs of quality query to use for creating the query
indexField - corresponding index field

SimpleQQParser

public SimpleQQParser(String qqName,
                      String indexField)
Constructor of a simple qq parser.

Parameters:
qqName - name-value pair of quality query to use for creating the query
indexField - corresponding index field
Method Detail

parse

public Query parse(QualityQuery qq)
            throws ParseException
Description copied from interface: QualityQueryParser
Parse a given QualityQuery into a Lucene query.

Specified by:
parse in interface QualityQueryParser
Parameters:
qq - the quality query to be parsed.
Throws:
ParseException - if parsing failed.