Пример #1
0
 /// <summary>
 /// Marks the stop words.
 /// </summary>
 /// <param name="tokens">The tokens.</param>
 /// <param name="language">The language.</param>
 /// <returns>The tokens.</returns>
 public Token[] MarkStopWords(Token[] tokens, StopWordsLanguage language)
 {
     if (tokens is null || tokens.Length == 0)
     {
         return(Array.Empty <Token>());
     }
     if (!StopWordsLanguages.TryGetValue(language, out var StopWords))
     {
         return(tokens);
     }
     return(StopWords.MarkStopWords(tokens));
 }