Package org.apache.solr.search
Interface ExtendedQuery
-
- All Known Subinterfaces:
PostFilter
- All Known Implementing Classes:
AbstractReRankQuery
,AnalyticsQuery
,CollapsingQParserPlugin.CollapsingPostFilter
,ExportQParserPlugin.ExportQuery
,ExtendedQueryBase
,FilterQuery
,FunctionRangeQuery
,RankQuery
,SolrRangeQuery
,WrappedQuery
public interface ExtendedQuery
The ExtendedQuery interface provides extra metadata to a query. Implementations of ExtendedQuery must also extend Query.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description boolean
getCache()
Should this query be cached in the query cache or filter cache.int
getCost()
Returns the cost of this query, used to order checking of filters that are not cached.default org.apache.lucene.search.Query
getCostAppliedQuery()
Returns this Query, applyingQueryUtils.makeQueryable(Query)
and maybe wrapping it to apply thegetCost()
if it's above zero.void
setCache(boolean cache)
void
setCost(int cost)
-
-
-
Method Detail
-
getCache
boolean getCache()
Should this query be cached in the query cache or filter cache.
-
setCache
void setCache(boolean cache)
-
getCost
int getCost()
Returns the cost of this query, used to order checking of filters that are not cached. If getCache()==false && getCost()>=100 && this instanceof PostFilter, then the PostFilter interface will be used for filtering. Otherwise, for smaller costs, this cost will be used forTwoPhaseIterator.matchCost()
.
-
setCost
void setCost(int cost)
-
getCostAppliedQuery
default org.apache.lucene.search.Query getCostAppliedQuery()
Returns this Query, applyingQueryUtils.makeQueryable(Query)
and maybe wrapping it to apply thegetCost()
if it's above zero. Subclasses may customize this if the query internally applies the configurable cost on the underlyingTwoPhaseIterator.matchCost()
.
-
-