Class OpenNLPTokenizerFactory
java.lang.Object
org.apache.lucene.analysis.AbstractAnalysisFactory
org.apache.lucene.analysis.TokenizerFactory
org.apache.lucene.analysis.opennlp.OpenNLPTokenizerFactory
- All Implemented Interfaces:
ResourceLoaderAware
Factory for
OpenNLPTokenizer.
<fieldType name="text_opennlp" class="solr.TextField" positionIncrementGap="100"
<analyzer>
<tokenizer class="solr.OpenNLPTokenizerFactory" sentenceModel="filename" tokenizerModel="filename"/>
</analyzer>
</fieldType>- Since:
- 7.3.0
- SPI Name (case-insensitive: if the name is 'htmlStrip', 'htmlstrip' can be used when looking up the service).
- "openNlp"
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringSPI namestatic final Stringstatic final StringFields inherited from class org.apache.lucene.analysis.AbstractAnalysisFactory
LUCENE_MATCH_VERSION_PARAM, luceneMatchVersion -
Constructor Summary
ConstructorsConstructorDescriptionDefault ctor for compatibility with SPIOpenNLPTokenizerFactory(Map<String, String> args) -
Method Summary
Modifier and TypeMethodDescriptioncreate(AttributeFactory factory) voidinform(ResourceLoader loader) Methods inherited from class org.apache.lucene.analysis.TokenizerFactory
availableTokenizers, create, findSPIName, forName, lookupClass, reloadTokenizersMethods inherited from class org.apache.lucene.analysis.AbstractAnalysisFactory
defaultCtorException, get, get, get, get, get, getBoolean, getChar, getClassArg, getFloat, getInt, getLines, getLuceneMatchVersion, getOriginalArgs, getPattern, getSet, getSnowballWordSet, getWordSet, isExplicitLuceneMatchVersion, require, require, require, requireBoolean, requireChar, requireFloat, requireInt, setExplicitLuceneMatchVersion, splitAt, splitFileNames
-
Field Details
-
NAME
SPI name- See Also:
-
SENTENCE_MODEL
- See Also:
-
TOKENIZER_MODEL
- See Also:
-
-
Constructor Details
-
OpenNLPTokenizerFactory
-
OpenNLPTokenizerFactory
public OpenNLPTokenizerFactory()Default ctor for compatibility with SPI
-
-
Method Details
-
create
- Specified by:
createin classTokenizerFactory
-
inform
- Specified by:
informin interfaceResourceLoaderAware- Throws:
IOException
-