I'm not certain, you should be able to instantiate PersonEndPoint
objects directly. The matter *might* be related to this:
https://cwiki.apache.org/CXF20DOC/wsdl-to-java.html#WSDLtoJava-wrapperstyle
(you may need to switch to wrapper style).
HTH,
Glen
On 07/20/2011 12:51 PM, Anthony Webster wrote:
Hi,
I have generated a webservice using wsdl2java and it all works fine. The
problem is that I'm exchanging PersonEndPoint objects and wsdl2java has set
all the properties to JAXBElement<...> (usually Strings). This makes
manipulating the objects received on the server side rather painful. So
instead of
Person person = new Person();
person.setName("Bob");
I have to go through
ObjectFactory of = new ObjectFactory();
PersonEndPoint person = of.createPersonEndPoint();
person.setFirstName(of.createPersonEndPointFirstName("Bob"));
Seems strange. Am I doing something wrong?
Many Thanks,
Anthony
--
Glen Mazza
Application Integration Division
Talend (http://www.talend.com/ai)
blog: http://www.jroller.com/gmazza