Thanks for the Howto. Basically the problem was that I used ParameterStyle.BARE in my webservice.
With wrapped parameters the interface looks ok and uses generics as you said. Thanks, Fabian -------- Original Message -------- Subject: Re: WSDL2Java question: Wrapped Lists (01-Okt-2008 23:47) From: Christian Schneider <[EMAIL PROTECTED]> To: [email protected] > You should take a look at this Howto: > http://cwiki.apache.org/CXF20DOC/defining-contract-first-webservices-with- > wsdl-generation-from-java.html > > The service gnerated here will have plain lists that make nice use of > generics. > > Greetings > > Christian > > The generated CustomerService looks like this: > > @WebService(targetNamespace = "http://customerservice.example.com/", > name = "CustomerService") > @XmlSeeAlso({ObjectFactory.class}) > > public interface CustomerService { > > /* > * > */ > > @WebResult(name = "return", targetNamespace = "") > @RequestWrapper(localName = "getCustomersByName", targetNamespace = > "http://customerservice.example.com/", className = > "com.example.customerservice.GetCustomersByName") > @ResponseWrapper(localName = "getCustomersByNameResponse", > targetNamespace = "http://customerservice.example.com/", className = > "com.example.customerservice.GetCustomersByNameResponse") > @WebMethod > public java.util.List<com.example.customerservice.Customer> > getCustomersByName( > @WebParam(name = "name", targetNamespace = "") > java.lang.String name > ) throws NoSuchCustomerException; > } > > [EMAIL PROTECTED] schrieb: > > Hello, > > > > I'm developing a web service with the java first approach. My domain > > model contains Hibernate annotations. > > As I don't want to share them with my webservice client, I thought it > > might be a good idea to use wsdl2java to generate a seperate model for > > the client which has no Hibernate annotations. > > > > There is just one thing I'm wondering about: Why does wsdl2java > > generate wrapper classes for Java lists (e.g.: List<Customer>)? > > > > Is there any annotation I could use to produce a WSDL file that doesn't > > use wrappers for lists? > > > > Thanks, > > > > Fabian > > > > > > > -- > > Christian Schneider > --- > http://www.liquid-reality.de >
