DotLucene 1.4 API Documentation |

# IndexWriter Methods

The methods of the IndexWriter class are listed below. For a complete list of IndexWriter class members, see the IndexWriter Members topic.

#### Public Instance Methods

AddDocument | Overloaded. Adds a document to this index, using the provided analyzer instead of the value of {@link .GetAnalyzer()}. If the document contains more than {@link .maxFieldLength} terms for a given Field, the remainder are discarded.
AddIndexes | Overloaded. Merges the provided indexes into this index. After this completes, the index is optimized. The provided IndexReaders are not closed.
Close | Flushes all changes to an index and closes all associated files.
DocCount | Returns the number of documents currently in this index.
Equals (inherited from Object) | Determines whether the specified Object is equal to the current Object.
GetAnalyzer | Returns the analyzer used by this index.
GetHashCode (inherited from Object) | Serves as a hash function for a particular type, suitable for use in hashing algorithms and data structures like a hash table.
GetSimilarity |
GetType (inherited from Object) | Gets the Type of the current instance.
GetUseCompoundFile | Setting to turn on usage of a compound file. When on, multiple files for each segment are merged into a single file once the segment creation is finished. This is done regardless of what directory is in use.
Optimize | Merges all segments together into a single segment, optimizing an index for search.
SetSimilarity | Expert: Set the Similarity implementation used by this IndexWriter.
SetUseCompoundFile | Setting to turn on usage of a compound file. When on, multiple files for each segment are merged into a single file once the segment creation is finished. This is done regardless of what directory is in use.
ToString (inherited from Object) | Returns a String that represents the current Object.

#### Protected Instance Methods

Finalize | Release the write lock, if needed.
MemberwiseClone (inherited from Object) | Creates a shallow copy of the current Object.

#### See Also

IndexWriter Class | Lucene.Net.Index Namespace