Lucene.Net  3.0.3
Lucene.Net is a .NET port of the Java Lucene Indexing Library
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Properties
Classes | Public Member Functions | Public Attributes | List of all members
Lucene.Net.Search.CachingSpanFilter Class Reference

Wraps another SpanFilter's result and caches it. The purpose is to allow filters to simply filter, and then wrap with this class to add caching. More...

Inherits Lucene.Net.Search.SpanFilter.

Public Member Functions

 CachingSpanFilter (SpanFilter filter)
 New deletions always result in a cache miss, by default (CachingWrapperFilter.DeletesMode.RECACHE.

Parameters
filterFilter to cache results of

 
 CachingSpanFilter (SpanFilter filter, CachingWrapperFilter.DeletesMode deletesMode)
 New deletions always result in a cache miss, specify the deletesMode
 
override DocIdSet GetDocIdSet (IndexReader reader)
 
 
override SpanFilterResult BitSpans (IndexReader reader)
 Returns a SpanFilterResult with true for documents which should be permitted in search results, and false for those that should not and Spans for where the true docs match.
 
override System.String ToString ()
 
override bool Equals (System.Object o)
 
override int GetHashCode ()
 

Public Attributes

int hitCount
 

Detailed Description

Wraps another SpanFilter's result and caches it. The purpose is to allow filters to simply filter, and then wrap with this class to add caching.

Definition at line 30 of file CachingSpanFilter.cs.

Constructor & Destructor Documentation

Lucene.Net.Search.CachingSpanFilter.CachingSpanFilter ( SpanFilter  filter)

New deletions always result in a cache miss, by default (CachingWrapperFilter.DeletesMode.RECACHE.

Parameters
filterFilter to cache results of

Definition at line 44 of file CachingSpanFilter.cs.

Lucene.Net.Search.CachingSpanFilter.CachingSpanFilter ( SpanFilter  filter,
CachingWrapperFilter.DeletesMode  deletesMode 
)

New deletions always result in a cache miss, specify the deletesMode

Parameters
filterFilter to cache results of
deletesModeSee CachingWrapperFilter.DeletesMode

Definition at line 52 of file CachingSpanFilter.cs.

Member Function Documentation

override SpanFilterResult Lucene.Net.Search.CachingSpanFilter.BitSpans ( IndexReader  reader)
virtual

Returns a SpanFilterResult with true for documents which should be permitted in search results, and false for those that should not and Spans for where the true docs match.

Parameters
readerThe Lucene.Net.Index.IndexReader to load position and DocIdSet information from
Returns
A SpanFilterResult

<throws> java.io.IOException if there was an issue accessing the necessary information </throws>

Implements Lucene.Net.Search.SpanFilter.

Definition at line 102 of file CachingSpanFilter.cs.

override bool Lucene.Net.Search.CachingSpanFilter.Equals ( System.Object  o)

Definition at line 112 of file CachingSpanFilter.cs.

override DocIdSet Lucene.Net.Search.CachingSpanFilter.GetDocIdSet ( IndexReader  reader)
virtual

Creates a DocIdSet enumerating the documents that should be permitted in search results. NOTE: null can be returned if no documents are accepted by this Filter.

Note: This method will be called once per segment in the index during searching. The returned DocIdSet must refer to document IDs for that segment, not for the top-level reader.

/summary>

Returns
a DocIdSet that provides the documents which should be permitted or prohibited in search results. NOTE: null can be returned if no documents will be accepted by this Filter.
Parameters
readerA IndexReader instance opened on the index currently searched on. Note, it is likely that the provided reader does not represent the whole underlying index i.e. if the index has more than one segment the given reader only represents a single segment.
See Also
DocIdBitSet

Implements Lucene.Net.Search.Filter.

Definition at line 74 of file CachingSpanFilter.cs.

override int Lucene.Net.Search.CachingSpanFilter.GetHashCode ( )

Definition at line 119 of file CachingSpanFilter.cs.

override System.String Lucene.Net.Search.CachingSpanFilter.ToString ( )

Definition at line 107 of file CachingSpanFilter.cs.

Member Data Documentation

int Lucene.Net.Search.CachingSpanFilter.hitCount

Definition at line 81 of file CachingSpanFilter.cs.


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