List of usage examples for org.apache.lucene.analysis CharArraySet unmodifiableSet
public static CharArraySet unmodifiableSet(CharArraySet set)
From source file:text_analyzer.SpanishAnalyzer.java
License:Apache License
/** * Builds an analyzer with the given stop words. If a non-empty stem exclusion set is * provided this analyzer will add a {@link KeywordMarkerFilter} before * stemming.//from w w w . j av a 2 s . c o m * * @param matchVersion lucene compatibility version * @param stopwords a stopword set * @param stemExclusionSet a set of terms not to be stemmed */ public SpanishAnalyzer(Version matchVersion, Set<?> stopwords, Set<?> stemExclusionSet) { super(matchVersion, stopwords); this.stemExclusionSet = CharArraySet.unmodifiableSet(CharArraySet.copy(matchVersion, stemExclusionSet)); }