facebook

java.lang.NoSuchMethodError: antlr.collections.AST.getLine()

  1. MyEclipse Archived
  2.  > 
  3. Application Servers and Deployment
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #307324 Reply

    houbbba
    Member

    Hello,

    I’ve just updated myEclipse pro from 8.0 to 8.5.
    I have a web project with Struts and Hibernate capabilities added.

    After the update and after re-deploying my web project on Tomcat 6, I’m getting the following error when first access on DB:
    java.lang.NoSuchMethodError: antlr.collections.AST.getLine().

    I’ve discovered this problem comes from an antlr jar conflict in the Struts 1.3 libraries and the Hibernate 3.2 Core libraries.
    The Struts libraries contain antlr-2.7.2.jar and the Hibernate one the antlr-2.7.6.jar.
    The missing method is only included in the 2.7.6 antlr version.

    After deployment, both jar files are included in my project, but it’s the 2.7.2 that is used.
    If I remove manualy this library, the problem is solved.

    Is there any possibility to avoid the 2.7.2 version to be deployed? It couldn’t prevent me having to remover the problematic jar file from my project after each deployment!

    Many thanks in advance for your help.

    Jerome.

    #307347

    Jerome,
    You can go to Window > Preferences > MyEclipse > Project Capabilities > Struts. From the Struts 1.3 tab, select the jar file and click on “Remove” and then “Apply”. This will remove the jar file from all the projects using Struts 1.3.
    The removed Jar file can be restored by clicking “Restore Defaults”.
    Let me know if that helps.

    #307388

    houbbba
    Member

    Helllo Shalini,

    Thanks you so much for your answer it worked!

    Best regards,
    Jerome.

    #307390

    Jerome,
    Good to know that it worked…
    Do let us know if you have any issues..

Viewing 4 posts - 1 through 4 (of 4 total)
Reply To: java.lang.NoSuchMethodError: antlr.collections.AST.getLine()

This topic is marked as closed to new replies, however your posting capabilities still allow you to do so.

You must be logged in to post in the forum log in