Class LuceneIndexScopeImpl
- java.lang.Object
-
- org.hibernate.search.backend.lucene.scope.impl.LuceneIndexScopeImpl
-
- All Implemented Interfaces:
LuceneIndexScope,IndexScope
public class LuceneIndexScopeImpl extends Object implements IndexScope, LuceneIndexScope
-
-
Constructor Summary
Constructors Constructor Description LuceneIndexScopeImpl(SearchBackendContext backendContext, BackendMappingContext mappingContext, Set<? extends LuceneScopeIndexManagerContext> indexManagerContexts)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.apache.lucene.index.IndexReaderopenIndexReader(Set<String> routingKeys)Opens an IndexReader on shards assigned to the given routing keys for all indexes containing the entities of the search scope.LuceneSearchQueryIndexScope<?>searchScope()StringtoString()-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.hibernate.search.engine.backend.scope.spi.IndexScope
extension
-
Methods inherited from interface org.hibernate.search.backend.lucene.scope.LuceneIndexScope
openIndexReader
-
-
-
-
Constructor Detail
-
LuceneIndexScopeImpl
public LuceneIndexScopeImpl(SearchBackendContext backendContext, BackendMappingContext mappingContext, Set<? extends LuceneScopeIndexManagerContext> indexManagerContexts)
-
-
Method Detail
-
searchScope
public LuceneSearchQueryIndexScope<?> searchScope()
- Specified by:
searchScopein interfaceIndexScope
-
openIndexReader
public org.apache.lucene.index.IndexReader openIndexReader(Set<String> routingKeys)
Description copied from interface:LuceneIndexScopeOpens an IndexReader on shards assigned to the given routing keys for all indexes containing the entities of the search scope.The instance must be closed after its use by the client of this class using
IndexReader.close().WARNING: Even if multi-tenancy is enabled, the returned reader exposes documents of *all* tenants.
- Specified by:
openIndexReaderin interfaceLuceneIndexScope- Parameters:
routingKeys- A collection containing zero, one or multiple string keys.- Returns:
- an IndexReader containing the entities of the index scope
-
-