Two classes have the same XML type name - problem
Jaxws does something that i find a bit strange when it generates the webservice, f.e:
public DoSomethingResponse doSomething(String data);
This code won't work for me , i get the "Two classes..." error when running wsgen. This problem occurs because jaxws generates a class for each method (haven't got anything to do with the object that's returned afaics) and that class is calles "method" + Response, in the case above, DoSomethingResponse. The same as the name of the response object. And thus, the "Two classes..." error.
There are of course solutions, the ones that i know of are:
1: make sure that the names of the response object and method doesn't match, f.e rename the responseobject to DoSomethingResponseVO or rename the method to executeSomething
3: add the @XmlType (namespace="http://namespacethatsnotthesameasthegenerated") annotation in each response class.
It's simple to fix the problem but i don't understand why jaxws couldn't just name the generated classes to something completely different. F.e doSomethingResponse__JaxwsImpl or something like that.
Anyone here that knows something about this ? Or perhaps yet another solution to avoid the problem above, f.e parameter when executing wsgen ?
I kinda like the DoSomethingResonse doSomething naming convention :-)