org.apache.lucene.search.spans

Class SpanNotQuery

public class SpanNotQuery extends SpanQuery

Removes matches which overlap with another SpanQuery.
Constructor Summary
SpanNotQuery(SpanQuery include, SpanQuery exclude)
Construct a SpanNotQuery matching spans from include which have no overlap with spans from exclude.
Method Summary
booleanequals(Object o)
Returns true iff o is equal to this.
voidextractTerms(Set terms)
SpanQuerygetExclude()
Return the SpanQuery whose matches must not overlap those returned.
StringgetField()
SpanQuerygetInclude()
Return the SpanQuery whose matches are filtered.
SpansgetSpans(IndexReader reader)
CollectiongetTerms()
Returns a collection of all terms matched by this query.
inthashCode()
Queryrewrite(IndexReader reader)
StringtoString(String field)

Constructor Detail

SpanNotQuery

public SpanNotQuery(SpanQuery include, SpanQuery exclude)
Construct a SpanNotQuery matching spans from include which have no overlap with spans from exclude.

Method Detail

equals

public boolean equals(Object o)
Returns true iff o is equal to this.

extractTerms

public void extractTerms(Set terms)

getExclude

public SpanQuery getExclude()
Return the SpanQuery whose matches must not overlap those returned.

getField

public String getField()

getInclude

public SpanQuery getInclude()
Return the SpanQuery whose matches are filtered.

getSpans

public Spans getSpans(IndexReader reader)

getTerms

public Collection getTerms()

Deprecated: use extractTerms instead

Returns a collection of all terms matched by this query.

See Also: extractTerms

hashCode

public int hashCode()

rewrite

public Query rewrite(IndexReader reader)

toString

public String toString(String field)
Copyright © 2000-2007 Apache Software Foundation. All Rights Reserved.