Class GenericDirectoryFactory
- Namespace
- Examine.Lucene.Directories
- Assembly
- Examine.Lucene.dll
Represents a generic directory factory
public class GenericDirectoryFactory : IDirectoryFactory, ITaxonomyDirectoryFactory
- Inheritance
-
GenericDirectoryFactory
- Implements
- Inherited Members
Constructors
GenericDirectoryFactory(Func<string, Directory>)
Creates an instance of GenericDirectoryFactory
public GenericDirectoryFactory(Func<string, Directory> factory)
Parameters
GenericDirectoryFactory(Func<string, Directory>, Func<string, Directory?>?)
Creates an instance of GenericDirectoryFactory
public GenericDirectoryFactory(Func<string, Directory> factory, Func<string, Directory?>? taxonomyDirectoryFactory)
Parameters
Methods
CreateDirectory(LuceneIndex, bool)
Creates the directory instance
public Directory CreateDirectory(LuceneIndex luceneIndex, bool forceUnlock)
Parameters
luceneIndexLuceneIndexforceUnlockboolIf true, will force unlock the directory when created
Returns
- Directory
Remarks
Any subsequent calls for the same index will return the same directory instance
CreateTaxonomyDirectory(LuceneIndex, bool)
Creates the directory instance for the Taxonomy Index
public Directory? CreateTaxonomyDirectory(LuceneIndex luceneIndex, bool forceUnlock)
Parameters
luceneIndexLuceneIndexforceUnlockboolIf true, will force unlock the directory when created
Returns
- Directory
The taxonomy directory, or null if taxonomy is not enabled for this index
Remarks
Any subsequent calls for the same index will return the same directory instance. If this returns null, taxonomy-based faceting will not be available for this index.