Class DirectoryTaxonomyIndexWriterFactory
This class offers some hooks for extending classes to control the Lucene.Net.Index.IndexWriter instance that is used by DirectoryTaxonomyWriter.
This class is specific to Lucene.NET to allow to customize the Lucene.Net.Index.IndexWriter instance and its configuration before it is used by DirectoryTaxonomyWriter.Inherited Members
Namespace: Lucene.Net.Facet.Taxonomy.Directory
Assembly: Lucene.Net.Facet.dll
Syntax
public class DirectoryTaxonomyIndexWriterFactory
Properties
Default
This class offers some hooks for extending classes to control the Lucene.Net.Index.IndexWriter instance that is used by DirectoryTaxonomyWriter.
This class is specific to Lucene.NET to allow to customize the Lucene.Net.Index.IndexWriter instance and its configuration before it is used by DirectoryTaxonomyWriter.Declaration
public static DirectoryTaxonomyIndexWriterFactory Default { get; }
Property Value
Type | Description |
---|---|
DirectoryTaxonomyIndexWriterFactory |
Methods
CreateIndexWriterConfig(OpenMode)
Create the Lucene.Net.Index.IndexWriterConfig that would be used for opening the internal index writer.
Extensions can configure the Lucene.Net.Index.IndexWriter as they see fit, including setting a Lucene.Net.Index.MergeScheduler, or Lucene.Net.Index.IndexDeletionPolicy, different RAM size etc. NOTE: internal docids of the configured index must not be altered. For that, categories are never deleted from the taxonomy index. In addition, merge policy in effect must not merge none adjacent segments.Declaration
public virtual IndexWriterConfig CreateIndexWriterConfig(OpenMode openMode)
Parameters
Type | Name | Description |
---|---|---|
OpenMode | openMode | see Lucene.Net.Index.OpenMode |
Returns
Type | Description |
---|---|
IndexWriterConfig |
See Also
OpenIndexWriter(Directory, IndexWriterConfig)
Open internal index writer, which contains the taxonomy data.
Extensions may provide their own Lucene.Net.Index.IndexWriter implementation or instance. NOTE: the instance this method returns will be disposed upon calling to Dispose(). NOTE: the merge policy in effect must not merge none adjacent segments. See comment in CreateIndexWriterConfig(OpenMode) for the logic behind this.Declaration
public virtual IndexWriter OpenIndexWriter(Directory directory, IndexWriterConfig config)
Parameters
Type | Name | Description |
---|---|---|
Directory | directory | the Lucene.Net.Store.Directory on top of which an Lucene.Net.Index.IndexWriter should be opened. |
IndexWriterConfig | config | configuration for the internal index writer. |
Returns
Type | Description |
---|---|
IndexWriter |