public class SpanOrQuery.SpanOrWeight extends SpanWeight
SpanWeight.PostingsWeight.DefaultBulkScorer| Modifier and Type | Field and Description |
|---|---|
(package private) java.util.List<SpanWeight> |
subWeights |
field, similarity, simScorerparentQuery| Constructor and Description |
|---|
SpanOrWeight(IndexSearcher searcher,
java.util.Map<Term,TermStates> terms,
java.util.List<SpanWeight> subWeights,
float boost) |
| Modifier and Type | Method and Description |
|---|---|
void |
extractTerms(java.util.Set<Term> terms)
Expert: adds all terms occurring in this query to the terms set.
|
void |
extractTermStates(java.util.Map<Term,TermStates> contexts)
Collect all TermStates used by this Weight
|
Spans |
getSpans(LeafReaderContext context,
SpanWeight.Postings requiredPostings)
Expert: Return a Spans object iterating over matches from this Weight
|
boolean |
isCacheable(LeafReaderContext ctx) |
explain, getSimScorer, matches, scorerbulkScorer, getQuery, scorerSupplierfinal java.util.List<SpanWeight> subWeights
public SpanOrWeight(IndexSearcher searcher, java.util.Map<Term,TermStates> terms, java.util.List<SpanWeight> subWeights, float boost) throws java.io.IOException
java.io.IOExceptionpublic void extractTerms(java.util.Set<Term> terms)
WeightWeight was created with needsScores == true then this
method will only extract terms which are used for scoring, otherwise it
will extract all terms which are used for matching.extractTerms in class Weightpublic boolean isCacheable(LeafReaderContext ctx)
true if the object can be cached against a given leafpublic void extractTermStates(java.util.Map<Term,TermStates> contexts)
SpanWeightextractTermStates in class SpanWeightcontexts - a map to add the TermStates topublic Spans getSpans(LeafReaderContext context, SpanWeight.Postings requiredPostings) throws java.io.IOException
SpanWeightgetSpans in class SpanWeightcontext - a LeafReaderContext for this Spansjava.io.IOException - on error