2 Replies - 464 Views - Last Post: 14 August 2017 - 06:55 AM

#1 roparzhhemon  Icon User is offline

  • New D.I.C Head

Reputation: -1
  • View blog
  • Posts: 19
  • Joined: 06-December 15

Misplaced jar files when importing a third-party project

Posted 14 August 2017 - 06:37 AM

Since I donwloaded and imported a third-party Java EE project, I find that the imported
project is full of strange error messages. One of those messages is "The hierarchy of the type T is inconsistent".



At https://stackoverflo...-is-inconsisten, the most upvoted answer advises to "refresh" (I did that and it changed nothing) or to "check the project's classpath and verify that the jar containing the interface or the class is in it".

But I am too much of a newbie in Java to understand this piece of advice. What is the "classpath" ? Is it the full directory path where the .java file is located ? If so, why should it contain a jar file ? I have many working projects, with no error message, where the directory containing the .java file does not contain any jar file.

Is This A Good Question/Topic? 0
  • +

Replies To: Misplaced jar files when importing a third-party project

#2 ndc85430  Icon User is online

  • D.I.C Lover
  • member icon

Reputation: 563
  • Posts: 2,297
  • Joined: 13-June 14

Re: Misplaced jar files when importing a third-party project

Posted 14 August 2017 - 06:43 AM

No, the classpath contains the directories that the JVM looks in to find the compiled classes. See, e.g. this.
Was This Post Helpful? 0
  • +
  • -

#3 roparzhhemon  Icon User is offline

  • New D.I.C Head

Reputation: -1
  • View blog
  • Posts: 19
  • Joined: 06-December 15

Re: Misplaced jar files when importing a third-party project

Posted 14 August 2017 - 06:55 AM

View Postndc85430, on 14 August 2017 - 01:43 PM, said:

No, the classpath contains the directories that the JVM looks in to find the compiled classes. See, e.g. this.


I read the doc page you linked to, and I do not find it very helpful at this point.
If I understood correctly, the classpath directory described in the doc page is the same for every project I have in Eclipse. Why then does this problem appear for the imported project and for no other project ?

I'm on a Mac, and doing java -version yields the following output :
java version "1.8.0_131"
Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)


Was This Post Helpful? 0
  • +
  • -

Page 1 of 1