public final class ScopedLuceneAnalyzer extends AnalyzerWrapper implements ScopedAnalyzer
ScopedLuceneAnalyzer
is a wrapper class containing all analyzers for a given class.
ScopedLuceneAnalyzer
behaves similar to PerFieldAnalyzerWrapper
by delegating requests for TokenStream
s to the underlying Analyzer
depending on the requested field name.Analyzer.ReuseStrategy, Analyzer.TokenStreamComponents
GLOBAL_REUSE_STRATEGY, PER_FIELD_REUSE_STRATEGY
Constructor and Description |
---|
ScopedLuceneAnalyzer(Analyzer globalAnalyzer) |
ScopedLuceneAnalyzer(Analyzer globalAnalyzer,
Map<String,Analyzer> scopedAnalyzers) |
Modifier and Type | Method and Description |
---|---|
protected Analyzer |
getWrappedAnalyzer(String fieldName) |
boolean |
isCompositeOfSameInstances(ScopedLuceneAnalyzer other)
Compares the references of the global analyzer backing this ScopedAnalyzer
and each scoped analyzer.
|
String |
toString() |
createComponents, getOffsetGap, getPositionIncrementGap, initReader, wrapComponents, wrapReader
close, getReuseStrategy, getVersion, setVersion, tokenStream, tokenStream
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
close
public ScopedLuceneAnalyzer(Analyzer globalAnalyzer)
public boolean isCompositeOfSameInstances(ScopedLuceneAnalyzer other)
other
- ScopedAnalyzer to compare toprotected Analyzer getWrappedAnalyzer(String fieldName)
getWrappedAnalyzer
in class AnalyzerWrapper
Copyright © 2006-2017 Red Hat, Inc. All Rights Reserved