// *** IStemmer interface implementation *** public string GetStem(string word) { Utils.ThrowException(word == null ? new ArgumentNullException("word") : null); mStemmer.SetCurrent(word); mStemmer.Stem(); return(mStemmer.GetCurrent()); }
// *** IStemmer interface implementation *** public string GetStem(string word) { Utils.ThrowException(word == null ? new ArgumentNullException("word") : null); try { ISnowballStemmer stemmer = CreateStemmer(); stemmer.SetCurrent(word); stemmer.Stem(); return(stemmer.GetCurrent()); } catch { return(word); } }