Sorry I don't quite follow. You're saying that in my service impl I shouldn't use an ObjectFactory to build/modify recieved/sent PersonEndPoint objects?
I'm going to look around for more info about wrapper style vs non-wrapper style (I'm quite new to all this). I was trying to find a contract-first example using conposite custom objects rather than just primitives (like the doubleit example) but no luck so far. Would you happen to know of one? Many Thanks, Anthony On Wednesday, 20 July 2011, Glen Mazza <[email protected]> wrote: > 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 > > >
