Maven jaxb2: xjc / jaxws: wsimport being added to eclipse?

I have a library that I create based on some WSDL / XSD definitions. I had a problem adding compiled classes to an eclipse project. I see that using the "mvn compile" .class files as well as .java files are generated. The problem is that even when creating .class files in eclipse, an error still appears in the import statement "import com.whatever.SomeService_Service", which was generated by one of the plugins. I tried to force the source to go into the project / src / main / java directory, but when the project is cleaned up, it deletes the files that I created. Has anyone come across this before / found a way to make it recognize that class files exist? Thank.

+3
source share
2 answers

An agreement with Maven is to generate code in target/generated-sources/<tool>, for example target/generated-sources/jax-ws.

Once created, run mvn eclipse:eclipseif you are using the maven eclipse plugin or right-click in your project and select Maven> Update Project Configuration if you are using M2Eclipse.

+2
source

Knowing that this is an old thread, but for reference only, I solved the problem with the following connector:

http://code.google.com/p/jaxws-maven-connector/

0
source

Source: https://habr.com/ru/post/1739377/


All Articles