Maven - Java EE 6 Javadocs Web Profile

Declaring the following dependency:

<dependency> <groupId>javax</groupId> <artifactId>javaee-web-api</artifactId> <version>6.0</version> <scope>provided</scope> </dependency> 

I can use everything I need for a Java EE 6 project (Servlet 3.0, JPA 2, EJB, CDI, etc.). The problem is that Maven cannot load Javadocs for dependencies (or at least m2eclipse โ€œDownload JavaDocโ€ does not work), so Eclipse does not show me Javadocs when I use the very convenient code completion function.

I found this post specific to Servlet 3.0 API, Maven dependency for Servlet 3.0 API? .

Can anyone point out a solution that works for each API? Or, can someone provide a dummy Java EE 6 Javadocs installation reference and link it to the javaee-web-api artifact in the local repository?

+7
source share
1 answer

Assuming you have Java EE javadocs, you can install them in your local maven repository using the maven install plugin. Look at this usage link

You should use -Dclassifier=sources to indicate that you are installing sources. For this, see this example .

+8
source

All Articles