You need to use our XJC "default value" plugin. Add: -xjc-Xdv
to the wsdl2java command line. Dan On Fri January 15 2010 11:20:57 am [email protected] wrote: > Hi, > > is it possible with CXF 2.1.2 to generate the elements which are sended > by/to the WSserver, with their default values declared as they are i nthe > WSDL ? > > like I've the element : > > <xs:complexType name="Personinfo"> > <xs:sequence> > <xs:element minOccurs="1" maxOccurs="1" name="param" > type="xs:string" default="test"> > </xs:element> > </xs:sequence> > </xs:complexType> > > and I would like wsdl2java to generate something like : > > public class Personinfo{ > > @XmlElement(name = "param") > protected String param = "test"; > > public String getParam() { > return param ; > } > > public void setParam(String value) { > this.param = value; > } > } > > > > is there a way to do that ? the argument "-defaultvalues" do not do that . > -- Daniel Kulp [email protected] http://www.dankulp.com/blog
