class LanguageToolAnalyzer extends Analyzer {

  private final JLanguageTool languageTool;
  private final boolean toLowerCase;

  public LanguageToolAnalyzer(JLanguageTool languageTool, boolean toLowerCase) {
    super();
    this.languageTool = languageTool;
    this.toLowerCase = toLowerCase;
  }

  @Override
  protected TokenStreamComponents createComponents(String s) {<FILL_FUNCTION_BODY>}

}

    Tokenizer tokenizer = new AnyCharTokenizer();
    TokenStream result = new LanguageToolFilter(tokenizer, languageTool, toLowerCase);
    return new TokenStreamComponents(tokenizer, result);
  
<no_super_class>