Closed Bouki closed 9 years ago
Hello Bouki and thanks for reporting.
This is an issue with different versions of the Google Guava library. They have added the splitToList() method "recently".
The Guava version that is currently used (0.5) is 16.0.1 and that was not changed since 2014-02-28. Version 0.4 was released on 2014-08-28. So no change here.
Guava has added the feature in version 15.0 see http://docs.guava-libraries.googlecode.com/git/javadoc/com/google/common/base/Splitter.html#splitToList(java.lang.CharSequence)
Therefore, from this point, all looks fine. Is it possible that in your build another older-than-15.0 Guava version is chosen instead?
Hello Thank you for your answer You're right I had a conflict, you can close this
Hello
There is an issue when I use the jar file here : http://search.maven.org/remotecontent?filepath=com/optimaize/languagedetector/language-detector/0.5/language-detector-0.5.jar
The code used is exactly the same on the readme part "How to Use"
The exception is caused by this line : List languageProfiles = new LanguageProfileReader().readAllBuiltIn();
And the exception is :
Exception in thread "main" java.lang.NoSuchMethodError: com.google.common.base.Splitter.splitToList(Ljava/lang/CharSequence;)Ljava/util/List;
at com.optimaize.langdetect.i18n.LdLocale.fromString(LdLocale.java:77)
at com.optimaize.langdetect.profiles.BuiltInLanguages.(BuiltInLanguages.java:21)
at com.optimaize.langdetect.profiles.LanguageProfileReader.readAllBuiltIn(LanguageProfileReader.java:118)
Please note that with v0.4 jar I don't have the issue and everthing is working fine