Class LuceneIndexProvider
- java.lang.Object
-
- org.apache.jackrabbit.oak.plugins.index.lucene.LuceneIndexProvider
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
,Observer
,QueryIndexProvider
public class LuceneIndexProvider extends java.lang.Object implements QueryIndexProvider, Observer, java.io.Closeable
A provider for Lucene indexes.- See Also:
LuceneIndex
-
-
Constructor Summary
Constructors Constructor Description LuceneIndexProvider()
LuceneIndexProvider(IndexCopier indexCopier)
LuceneIndexProvider(IndexTracker tracker)
LuceneIndexProvider(IndexTracker tracker, IndexAugmentorFactory augmentorFactory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
void
contentChanged(@NotNull NodeState root, @NotNull CommitInfo info)
Observes a content change.@NotNull java.util.List<QueryIndex>
getQueryIndexes(NodeState nodeState)
Get the currently configured indexes.void
setAggregator(QueryIndex.NodeAggregator aggregator)
sets the default node aggregator that will be used at query timeLuceneIndexProvider
with(QueryIndex.NodeAggregator analyzer)
-
-
-
Constructor Detail
-
LuceneIndexProvider
public LuceneIndexProvider()
-
LuceneIndexProvider
public LuceneIndexProvider(IndexCopier indexCopier)
-
LuceneIndexProvider
public LuceneIndexProvider(IndexTracker tracker)
-
LuceneIndexProvider
public LuceneIndexProvider(IndexTracker tracker, IndexAugmentorFactory augmentorFactory)
-
-
Method Detail
-
close
public void close()
- Specified by:
close
in interfacejava.lang.AutoCloseable
- Specified by:
close
in interfacejava.io.Closeable
-
contentChanged
public void contentChanged(@NotNull @NotNull NodeState root, @NotNull @NotNull CommitInfo info)
Description copied from interface:Observer
Observes a content change. See theObserver
class javadocs and relevant repository and observer registration details for more information on when and how this method gets called.- Specified by:
contentChanged
in interfaceObserver
- Parameters:
root
- root state of the repositoryinfo
- commit information
-
getQueryIndexes
@NotNull public @NotNull java.util.List<QueryIndex> getQueryIndexes(NodeState nodeState)
Description copied from interface:QueryIndexProvider
Get the currently configured indexes.- Specified by:
getQueryIndexes
in interfaceQueryIndexProvider
- Parameters:
nodeState
- the node state of the root- Returns:
- the list of indexes
-
setAggregator
public void setAggregator(QueryIndex.NodeAggregator aggregator)
sets the default node aggregator that will be used at query time- Parameters:
aggregator
- the node aggregator
-
with
public LuceneIndexProvider with(QueryIndex.NodeAggregator analyzer)
-
-