flybywire
flybywire

Reputation: 274080

find pom dependencies by classname

How can I found the dependency by classname?

In particular, I want to include this class org.mortbay.jetty.testing.ServletTester in my project, how do I do that? And how did you find the answer?

Upvotes: 18

Views: 7313

Answers (3)

Rich Seller
Rich Seller

Reputation: 84088

Nexus allows you to search for artifacts by class name as well as GroupId, ArtifactId, and Version. Nexus uses Lucene to index artifacts. The Sonatype public repository allows you to search the major repositories.

Enter org.mortbay.jetty.testing.ServletTester in the search field and hit the search icon. You'll get no results because by default Nexus searches for keywords. To refine the search to match class names, select the down arrow next to the Keyword Search label on the search page and select Classname search (see screenshot). You'll then find a list of matching artifacts.

search screenshot
(source: sonatype.com)

Nexus also has Opensearch integration, so you can add the search to your Firefox / IE 7 search field. See the Nexus book for more details on setting this up.

There's also a video with more details on the search options available.

Upvotes: 11

DanLebrero
DanLebrero

Reputation: 8591

Use http://www.jarvana.com/ or use Intellij IDEA

Upvotes: -1

dfa
dfa

Reputation: 116442

since version 6.1, Netbeans can add to pom.xml the dependency you need for a given class

Upvotes: 1

Related Questions