I have a library I am creating based on some WSDL/XSD definitions. I am having a problem having the compiled classes added in the eclipse project. I can see that with a 'mvn compile' that the .class files are generated, as well as the .java files. The problem is that even though the .class files are generated, eclipse is still showing an error on the import statement "import com.whatever.SomeService_Service" that was generated by one of the plugins. I tried forcing the source to go into the project/src/main/java directory, but when the project is cleaned, it deletes files that I have created. Has anyone run into this before/found a way to get it to recognize that the class files are there? Thanks.
+1
A:
The convention with Maven is to generate code in target/generated-sources/<tool>
, for example target/generated-sources/jax-ws
.
Once generated, run mvn eclipse:eclipse
if you are using the maven eclipse plugin or right-click on your project and select Maven > Update Project Configuration if you are using M2Eclipse.
Pascal Thivent
2010-03-31 21:41:31