Back to LanguageTool Homepage - Privacy - Imprint

Why NoClassDefFoundError

code is below:

langTool = new JLanguageTool(new AmericanEnglish());

Exception is below:

Exception in thread “main” java.lang.NoClassDefFoundError: morfologik/stemming/IStemmer
at org.languagetool.language.English.getTagger(English.java:91)
at org.languagetool.JLanguageTool.(JLanguageTool.java:197)
at org.languagetool.JLanguageTool.(JLanguageTool.java:167)

BTW, I didn`t find the latest jar of languagetool,so I used the languagetool-2.0.1.jar instead.

Please see http://wiki.languagetool.org/java-api - we strongly recommend using Maven (or Gradle), it will take care of the dependencies and avoid errors like this.