Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

The resource is not on the build path of a java project?

Tags:

eclipse

maven

I have a Maven project on my Eclipse. When I perform call hierarchy I get the message:

The resource is not on the build path of a java project.

What needs to be configured for this?

like image 209
user1954970 Avatar asked Aug 05 '13 12:08

user1954970


3 Answers

I followed the following steps it worked:

  1. Properties->project facets->check java->ok
  2. convert to maven project.
like image 191
user1954970 Avatar answered Nov 01 '22 17:11

user1954970


I have this quite often. Seems bug in Eclipse. Quit/restart Eclipse seems the easiest to get things working again.

like image 24
nomail Avatar answered Nov 01 '22 16:11

nomail


Assuming you're expecting a call hierarchy in your own code, ensure that all sources are located in the src/main/java directory.

Have you installed the Eclipse m2e plugin? Does your Eclipse recognize the project as a Maven project? (right click > maven > convert to maven project)

like image 22
Gab Avatar answered Nov 01 '22 15:11

Gab