Class SpanNearPayloadCheckQuery
Only return those matches that have a specific payload at the given position.
Inherited Members
Namespace: Lucene.Net.Search.Spans
Assembly: Lucene.Net.dll
Syntax
public class SpanNearPayloadCheckQuery : SpanPositionCheckQuery
Constructors
SpanNearPayloadCheckQuery(SpanNearQuery, ICollection<byte[]>)
Only return those matches that have a specific payload at the given position.
Declaration
public SpanNearPayloadCheckQuery(SpanNearQuery match, ICollection<byte[]> payloadToMatch)
Parameters
Type | Name | Description |
---|---|---|
SpanNearQuery | match | The underlying SpanQuery to check. |
ICollection<byte[]> | payloadToMatch | The ICollection{byte[]} of payloads to match. IMPORTANT: If the type provided does not implement IList<T> (including arrays) or ISet<T>, it should either implement IStructuralEquatable or override Equals(object) and GetHashCode() with implementations that compare the values of the byte arrays to ensure they are the same. |
Fields
m_payloadToMatch
Only return those matches that have a specific payload at the given position.
Declaration
protected readonly ICollection<byte[]> m_payloadToMatch
Field Value
Type | Description |
---|---|
ICollection<byte[]> |
Methods
AcceptPosition(Spans)
Implementing classes are required to return whether the current position is a match for the passed in "match" SpanQuery.
This is only called if the underlying MoveNext() for the match is successfulDeclaration
protected override SpanPositionCheckQuery.AcceptStatus AcceptPosition(Spans spans)
Parameters
Type | Name | Description |
---|---|---|
Spans | spans | The Spans instance, positioned at the spot to check |
Returns
Type | Description |
---|---|
SpanPositionCheckQuery.AcceptStatus | Whether the match is accepted, rejected, or rejected and should move to the next doc. |
Overrides
See Also
Clone()
Returns a clone of this query.
Declaration
public override object Clone()
Returns
Type | Description |
---|---|
object |
Overrides
Equals(object)
Determines whether the specified object is equal to the current object.
Declaration
public override bool Equals(object o)
Parameters
Type | Name | Description |
---|---|---|
object | o |
Returns
Type | Description |
---|---|
bool | true if the specified object is equal to the current object; otherwise, false. |
Overrides
GetHashCode()
Serves as the default hash function.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
int | A hash code for the current object. |
Overrides
ToString(string)
Prints a query to a string, with field
assumed to be the
default field and omitted.
Declaration
public override string ToString(string field)
Parameters
Type | Name | Description |
---|---|---|
string | field |
Returns
Type | Description |
---|---|
string |