Gabriel
Gabriel

Reputation: 197

how to find the source of a java package/class

Working on a large legacy maven based project.

some classes import com.example.somenamespace.someclass, which is nowhere to be found on the dependency list on pom.xml

mvn dependency:tree do not show anything even close to that namespace. How do I figure out what is making maven to pull that jar?

Upvotes: 0

Views: 580

Answers (1)

Laird Nelson
Laird Nelson

Reputation: 16154

This is not quite a Maven answer, but I think it will be useful to you.

If an artifact comes from Maven Central, you can search Maven Central by fully-qualified classname.

Your question refers to a class, which of course will not ever appear in mvn dependency:tree, which deals exclusively with artifacts.

Upvotes: 4

Related Questions