Lucene.Net  3.0.3
Lucene.Net is a port of the Lucene search engine library, written in C# and targeted at .NET runtime users.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Properties Pages
Public Member Functions | Protected Member Functions | List of all members
Lucene.Net.Search.FilteredDocIdSetIterator Class Referenceabstract

Abstract decorator class of a DocIdSetIterator implementation that provides on-demand filter/validation mechanism on an underlying DocIdSetIterator. See FilteredDocIdSet More...

Inherits Lucene.Net.Search.DocIdSetIterator.

Inherited by Lucene.Net.Search.FilteredDocIdSet.AnonymousClassFilteredDocIdSetIterator.

Public Member Functions

abstract bool Match (int doc)
 Validation method to determine whether a docid should be in the result set.
 
override int DocID ()
 Returns the following:


 
override int NextDoc ()
 Advances to the next document in the set and returns the doc it is currently on, or NO_MORE_DOCS if there are no more docs in the set.

 
override int Advance (int target)
 Advances to the first beyond the current whose document number is greater than or equal to target. Returns the current document number or NO_MORE_DOCS if there are no more docs in the set. Behaves as if written:
 

Protected Member Functions

 FilteredDocIdSetIterator (DocIdSetIterator innerIter)
 Constructor.
 

Additional Inherited Members

- Static Public Attributes inherited from Lucene.Net.Search.DocIdSetIterator
static readonly int NO_MORE_DOCS = System.Int32.MaxValue
 When returned by NextDoc(), Advance(int) and DocID() it means there are no more docs in the iterator.
 

Detailed Description

Abstract decorator class of a DocIdSetIterator implementation that provides on-demand filter/validation mechanism on an underlying DocIdSetIterator. See FilteredDocIdSet

Definition at line 28 of file FilteredDocIdSetIterator.cs.

Constructor & Destructor Documentation

Lucene.Net.Search.FilteredDocIdSetIterator.FilteredDocIdSetIterator ( DocIdSetIterator  innerIter)
protected

Constructor.

Parameters
innerIterUnderlying DocIdSetIterator.

Definition at line 36 of file FilteredDocIdSetIterator.cs.

Member Function Documentation

override int Lucene.Net.Search.FilteredDocIdSetIterator.Advance ( int  target)
virtual

Advances to the first beyond the current whose document number is greater than or equal to target. Returns the current document number or NO_MORE_DOCS if there are no more docs in the set. Behaves as if written:

int advance(int target) { int doc; while ((doc = nextDoc()) < target) { } return doc; }

Some implementations are considerably more efficient than that.

NOTE: certain implemenations may return a different value (each time) if called several times in a row with the same target.

NOTE: this method may be called with NO_MORE_DOCS for efficiency by some Scorers. If your implementation cannot efficiently determine that it should exhaust, it is recommended that you check for that value in each call to this method.

NOTE: after the iterator has exhausted you should not call this method, as it may result in unpredicted behavior.

<since>2.9</since>

Implements Lucene.Net.Search.DocIdSetIterator.

Definition at line 72 of file FilteredDocIdSetIterator.cs.

override int Lucene.Net.Search.FilteredDocIdSetIterator.DocID ( )
virtual

Returns the following:

Implements Lucene.Net.Search.DocIdSetIterator.

Definition at line 55 of file FilteredDocIdSetIterator.cs.

abstract bool Lucene.Net.Search.FilteredDocIdSetIterator.Match ( int  doc)
pure virtual

Validation method to determine whether a docid should be in the result set.

Parameters
docdocid to be tested
Returns
true if input docid should be in the result set, false otherwise.
See Also
FilteredDocIdSetIterator(DocIdSetIterator)
override int Lucene.Net.Search.FilteredDocIdSetIterator.NextDoc ( )
virtual

Advances to the next document in the set and returns the doc it is currently on, or NO_MORE_DOCS if there are no more docs in the set.

NOTE: after the iterator has exhausted you should not call this method, as it may result in unpredicted behavior.

Implements Lucene.Net.Search.DocIdSetIterator.

Definition at line 60 of file FilteredDocIdSetIterator.cs.


The documentation for this class was generated from the following file: