java.lang.IllegalArgumentException

Could not create enum

Samebug tips0

We couldn't find tips for this exception.

Don't give up yet. Paste your full stack trace to get a solution.

Solutions on the web419

  • via Unknown by Unknown author,
  • Stack trace

    • java.lang.IllegalArgumentException: Could not create enum at com.hankcs.hanlp.corpus.util.EnumBuster.make(EnumBuster.java:99) at com.hankcs.hanlp.corpus.util.EnumBuster.make(EnumBuster.java:68) at com.hankcs.hanlp.corpus.util.CustomNatureUtility.addNature(CustomNatureUtility.java:58) at com.hankcs.hanlp.corpus.tag.Nature.create(Nature.java:829) at com.hankcs.demo.DemoCustomNature.main(DemoCustomNature.java:41) Caused by: java.lang.IllegalArgumentException: Could not create the class at com.hankcs.hanlp.corpus.util.EnumBuster$Memento.<init>(EnumBuster.java:453) at com.hankcs.hanlp.corpus.util.EnumBuster$Memento.<init>(EnumBuster.java:439) at com.hankcs.hanlp.corpus.util.EnumBuster.make(EnumBuster.java:91) ... 4 more Caused by: java.lang.NoSuchFieldException: $VALUES at java.lang.Class.getDeclaredField(Class.java:1961) at com.hankcs.hanlp.corpus.util.EnumBuster.findValuesField(EnumBuster.java:349) at com.hankcs.hanlp.corpus.util.EnumBuster.values(EnumBuster.java:429) at com.hankcs.hanlp.corpus.util.EnumBuster.access$0(EnumBuster.java:426) at com.hankcs.hanlp.corpus.util.EnumBuster$Memento.<init>(EnumBuster.java:443)

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    Hiren AmaliyarHiren Amaliyar
    1836 times, last one
    jokesterjokester
    Once,
    Unknown visitor
    Unknown visitorOnce,
    andreeaa marinandreeaa marin
    Once,
    VikramVikram
    2 times, last one
    57 more bugmates