Package org.apache.lucene.analysis
Class DelegatingAnalyzerWrapper.DelegatingReuseStrategy
- java.lang.Object
-
- org.apache.lucene.analysis.Analyzer.ReuseStrategy
-
- org.apache.lucene.analysis.DelegatingAnalyzerWrapper.DelegatingReuseStrategy
-
- Enclosing class:
- DelegatingAnalyzerWrapper
private static final class DelegatingAnalyzerWrapper.DelegatingReuseStrategy extends Analyzer.ReuseStrategy
-
-
Field Summary
Fields Modifier and Type Field Description private Analyzer.ReuseStrategyfallbackStrategy(package private) DelegatingAnalyzerWrapperwrapper
-
Constructor Summary
Constructors Constructor Description DelegatingReuseStrategy(Analyzer.ReuseStrategy fallbackStrategy)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Analyzer.TokenStreamComponentsgetReusableComponents(Analyzer analyzer, java.lang.String fieldName)Gets the reusable TokenStreamComponents for the field with the given name.voidsetReusableComponents(Analyzer analyzer, java.lang.String fieldName, Analyzer.TokenStreamComponents components)Stores the given TokenStreamComponents as the reusable components for the field with the give name.-
Methods inherited from class org.apache.lucene.analysis.Analyzer.ReuseStrategy
getStoredValue, setStoredValue
-
-
-
-
Field Detail
-
wrapper
DelegatingAnalyzerWrapper wrapper
-
fallbackStrategy
private final Analyzer.ReuseStrategy fallbackStrategy
-
-
Constructor Detail
-
DelegatingReuseStrategy
DelegatingReuseStrategy(Analyzer.ReuseStrategy fallbackStrategy)
-
-
Method Detail
-
getReusableComponents
public Analyzer.TokenStreamComponents getReusableComponents(Analyzer analyzer, java.lang.String fieldName)
Description copied from class:Analyzer.ReuseStrategyGets the reusable TokenStreamComponents for the field with the given name.- Specified by:
getReusableComponentsin classAnalyzer.ReuseStrategy- Parameters:
analyzer- Analyzer from which to get the reused components. UseAnalyzer.ReuseStrategy.getStoredValue(Analyzer)andAnalyzer.ReuseStrategy.setStoredValue(Analyzer, Object)to access the data on the Analyzer.fieldName- Name of the field whose reusable TokenStreamComponents are to be retrieved- Returns:
- Reusable TokenStreamComponents for the field, or
nullif there was no previous components for the field
-
setReusableComponents
public void setReusableComponents(Analyzer analyzer, java.lang.String fieldName, Analyzer.TokenStreamComponents components)
Description copied from class:Analyzer.ReuseStrategyStores the given TokenStreamComponents as the reusable components for the field with the give name.- Specified by:
setReusableComponentsin classAnalyzer.ReuseStrategyfieldName- Name of the field whose TokenStreamComponents are being setcomponents- TokenStreamComponents which are to be reused for the field
-
-