Class DirectoryCreationContextImpl
- java.lang.Object
-
- org.hibernate.search.backend.lucene.lowlevel.directory.impl.DirectoryCreationContextImpl
-
- All Implemented Interfaces:
DirectoryCreationContext
public class DirectoryCreationContextImpl extends Object implements DirectoryCreationContext
The implementation ofDirectoryCreationContext.- Author:
- Emmanuel Bernard, Sanne Grinovero, Hardy Ferentschik, Gunnar Morling
-
-
Constructor Summary
Constructors Constructor Description DirectoryCreationContextImpl(EventContext eventContext, String indexName, Optional<String> shardId, BeanResolver beanResolver, ConfigurationPropertySource configurationPropertySource)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BeanResolverbeanResolver()ConfigurationPropertySourceconfigurationPropertySource()Optional<Supplier<org.apache.lucene.store.LockFactory>>createConfiguredLockFactorySupplier()EventContexteventContext()StringindexName()Optional<String>shardId()
-
-
-
Constructor Detail
-
DirectoryCreationContextImpl
public DirectoryCreationContextImpl(EventContext eventContext, String indexName, Optional<String> shardId, BeanResolver beanResolver, ConfigurationPropertySource configurationPropertySource)
-
-
Method Detail
-
eventContext
public EventContext eventContext()
- Specified by:
eventContextin interfaceDirectoryCreationContext- Returns:
- The event context to use for exceptions.
-
indexName
public String indexName()
- Specified by:
indexNamein interfaceDirectoryCreationContext- Returns:
- The name of the index in Hibernate Search.
-
shardId
public Optional<String> shardId()
- Specified by:
shardIdin interfaceDirectoryCreationContext- Returns:
- The identifier of the index shard, if relevant.
-
beanResolver
public BeanResolver beanResolver()
- Specified by:
beanResolverin interfaceDirectoryCreationContext- Returns:
- A
BeanResolver.
-
configurationPropertySource
public ConfigurationPropertySource configurationPropertySource()
- Specified by:
configurationPropertySourcein interfaceDirectoryCreationContext- Returns:
- A configuration property source, appropriately masked so that the factory doesn't need to care about Hibernate Search prefixes (hibernate.search.*, etc.). All the properties can be accessed at the root. CAUTION: the property key "type" is reserved for use by the engine.
-
createConfiguredLockFactorySupplier
public Optional<Supplier<org.apache.lucene.store.LockFactory>> createConfiguredLockFactorySupplier()
- Specified by:
createConfiguredLockFactorySupplierin interfaceDirectoryCreationContext
-
-