| org.apache.solr.search.SolrQueryParser
SolrQueryParser | public class SolrQueryParser extends QueryParser (Code) | | A variation on the Lucene QueryParser which knows about the field
types and query time analyzers configured in Solr's schema.xml.
This class also deviates from the Lucene QueryParser by using
ConstantScore versions of RangeQuery and PrefixQuery to prevent
TooManyClauses exceptions.
If the magic field name "_val_ " is used in a term or
phrase query, the value is parsed as a function.
See Also: QueryParsing.parseFunction See Also: ConstantScoreRangeQuery See Also: ConstantScorePrefixQuery author: yonik |
Constructor Summary | |
public | SolrQueryParser(IndexSchema schema, String defaultField) Constructs a SolrQueryParser using the schema to understand the
formats and datatypes of each field. |
SolrQueryParser | public SolrQueryParser(IndexSchema schema, String defaultField)(Code) | | Constructs a SolrQueryParser using the schema to understand the
formats and datatypes of each field. Only the defaultSearchField
will be used from the IndexSchema (unless overridden),
<solrQueryParser> will not be used.
Parameters: schema - Used for default search field name if defaultField is null and field information is used for analysis Parameters: defaultField - default field used for unspecified search terms. if null, the schema default field is used See Also: IndexSchema.getSolrQueryParser(String defaultField) |
getFieldQuery | protected Query getFieldQuery(String field, String queryText) throws ParseException(Code) | | |
getPrefixQuery | protected Query getPrefixQuery(String field, String termStr) throws ParseException(Code) | | |
getRangeQuery | protected Query getRangeQuery(String field, String part1, String part2, boolean inclusive) throws ParseException(Code) | | |
|
|