Class SpanPayloadCheckQuery
- java.lang.Object
-
- org.apache.lucene.search.Query
-
- org.apache.lucene.queries.spans.SpanQuery
-
- org.apache.lucene.queries.payloads.SpanPayloadCheckQuery
-
public class SpanPayloadCheckQuery extends SpanQuery
Only return those matches that have a specific payload at the given position.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classSpanPayloadCheckQuery.MatchOperationThe payload type.static classSpanPayloadCheckQuery.PayloadTypeThe payload type.classSpanPayloadCheckQuery.SpanPayloadCheckWeightWeight that pulls its Spans using a PayloadSpanCollector
-
Field Summary
Fields Modifier and Type Field Description protected SpanQuerymatchprotected SpanPayloadCheckQuery.MatchOperationoperationprotected List<BytesRef>payloadToMatchprotected SpanPayloadCheckQuery.PayloadTypepayloadType
-
Constructor Summary
Constructors Constructor Description SpanPayloadCheckQuery(SpanQuery match, List<BytesRef> payloadToMatch)SpanPayloadCheckQuery(SpanQuery match, List<BytesRef> payloadToMatch, SpanPayloadCheckQuery.PayloadType payloadType, SpanPayloadCheckQuery.MatchOperation operation)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SpanWeightcreateWeight(IndexSearcher searcher, ScoreMode scoreMode, float boost)booleanequals(Object other)StringgetField()Returns the name of the field matched by this query.inthashCode()Queryrewrite(IndexSearcher indexSearcher)StringtoString(String field)voidvisit(QueryVisitor visitor)-
Methods inherited from class org.apache.lucene.queries.spans.SpanQuery
getTermStates, getTermStates
-
Methods inherited from class org.apache.lucene.search.Query
classHash, rewrite, sameClassAs, toString
-
-
-
-
Field Detail
-
match
protected final SpanQuery match
-
operation
protected final SpanPayloadCheckQuery.MatchOperation operation
-
payloadType
protected final SpanPayloadCheckQuery.PayloadType payloadType
-
-
Constructor Detail
-
SpanPayloadCheckQuery
public SpanPayloadCheckQuery(SpanQuery match, List<BytesRef> payloadToMatch, SpanPayloadCheckQuery.PayloadType payloadType, SpanPayloadCheckQuery.MatchOperation operation)
-
-
Method Detail
-
getField
public String getField()
Description copied from class:SpanQueryReturns the name of the field matched by this query.
-
createWeight
public SpanWeight createWeight(IndexSearcher searcher, ScoreMode scoreMode, float boost) throws IOException
- Specified by:
createWeightin classSpanQuery- Throws:
IOException
-
rewrite
public Query rewrite(IndexSearcher indexSearcher) throws IOException
- Overrides:
rewritein classQuery- Throws:
IOException
-
visit
public void visit(QueryVisitor visitor)
-
-