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
Classes | Public Member Functions | Protected Member Functions | Protected Attributes | Properties | List of all members
Lucene.Net.Index.FieldEnumerator< T > Class Template Referenceabstract

More...

Inherits IDisposable.

Inherited by Lucene.Net.Index.FieldEnumerator< T >.TermEnumerator, Lucene.Net.Index.FieldEnumerator< T >.TermEnumerator, Lucene.Net.Index.NumericFieldEnum< T >, and Lucene.Net.Index.StringFieldEnumerator.

Classes

class  TermEnumerator
 The enumerator over the terms in an index. More...
 

Public Member Functions

void Dispose ()
 Dispose of the instance.
 

Protected Member Functions

void Init (IndexReader reader, string field)
 Initialization method called by subclasses to simulate a shared base constructor as generic classes cannot have a parameterized ctor.
 
void Init (IndexReader reader, string fieldName, bool includeDocs)
 Initialization method called by subclasses to simulate a shared base constructor as generic classes cannot have a parameterized ctor.
 
abstract bool TryParse (string s)
 Method to attempt to parse out the value from the encoded string and sets the value of Current.
 

Protected Attributes

bool includeDocs
 Whether the enumerator will include TermDocs.
 
TermEnumerator tEnum
 The specialized TermEnum enumerator.
 

Properties

TermEnumerator Terms [get]
 Access the enumerator for the terms.
 
TermDocEnumerator.TermDocUsingTermsEnumerator Docs [get]
 Access the enumerator for the TermDocs.
 

Detailed Description

Base class for the typed enumerators.

There are five implementations of FieldEnumeratorT for strings, integers, longs, floats, and doubles. The numeric enumerators support both standard Field and NumericField implementations. The string and numeric enumerators have slightly different options, but both should be used within a using statment to close the underlying TermEnum/TermDocs. Refer to the unit tests for usage examples.

Template Parameters
TThe type of data being enumerated.

Definition at line 49 of file FieldEnumerator.cs.

Member Function Documentation

void Lucene.Net.Index.FieldEnumerator< T >.Dispose ( )

Dispose of the instance.

Definition at line 150 of file FieldEnumerator.cs.

void Lucene.Net.Index.FieldEnumerator< T >.Init ( IndexReader  reader,
string  field 
)
protected

Initialization method called by subclasses to simulate a shared base constructor as generic classes cannot have a parameterized ctor.

Parameters
readerThe index reader to read from.
fieldThe field to enumerate.

Definition at line 87 of file FieldEnumerator.cs.

void Lucene.Net.Index.FieldEnumerator< T >.Init ( IndexReader  reader,
string  fieldName,
bool  includeDocs 
)
protected

Initialization method called by subclasses to simulate a shared base constructor as generic classes cannot have a parameterized ctor.

Parameters
readerThe index reader to read from.
fieldNameThe field to enumerate.
includeDocsWhether this enumerator will support TermDocs.

Definition at line 99 of file FieldEnumerator.cs.

abstract bool Lucene.Net.Index.FieldEnumerator< T >.TryParse ( string  s)
protectedpure virtual

Method to attempt to parse out the value from the encoded string and sets the value of Current.

Parameters
sThe encoded string.
Returns
True if the value was successfully parsed, false if we reached the end of encoded values in the fiele and only the tries remain.

Implemented in Lucene.Net.Index.NumericFieldEnum< T >, and Lucene.Net.Index.StringFieldEnumerator.

Member Data Documentation

bool Lucene.Net.Index.FieldEnumerator< T >.includeDocs
protected

Whether the enumerator will include TermDocs.

Definition at line 54 of file FieldEnumerator.cs.

TermEnumerator Lucene.Net.Index.FieldEnumerator< T >.tEnum
protected

The specialized TermEnum enumerator.

Definition at line 69 of file FieldEnumerator.cs.

Property Documentation

TermDocEnumerator.TermDocUsingTermsEnumerator Lucene.Net.Index.FieldEnumerator< T >.Docs
get

Access the enumerator for the TermDocs.

Definition at line 131 of file FieldEnumerator.cs.

TermEnumerator Lucene.Net.Index.FieldEnumerator< T >.Terms
get

Access the enumerator for the terms.

Definition at line 123 of file FieldEnumerator.cs.


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