On Wednesday, May 25, 2011 4:52:09 AM meteora28 wrote:
> I have an unknown element in my generated Java coud through wsdl2java.
> 
> The API says that there are only 3 optional elements: name, namespace and
> type
> http://download.oracle.com/javase/6/docs/api/javax/xml/bind/annotation/XmlE
> lementRef.html
> 
> Where does the element "required" come from? My IDE shows this correctly as
> an error, isn't it?
> 
> @XmlElementRef(name = "InitialTerminationTime", namespace =
> "http://docs.oasis-open.org/wsn/b-2";, type = JAXBElement.class, required =
> false)

It's part of JAXB 2.2 which is what is required for the JAX-WS 2.2 compliant 
code generator.   For CXF  2.4, you can run "wsdl2java -fe jaxws21 ....." to 
generate 2.1 compliant code instead which, I think, will change this for you.   
If not, you may need to endorse the jaxb-api 2.2 jar.

 -- 
Daniel Kulp
[email protected]
http://dankulp.com/blog
Talend - http://www.talend.com

Reply via email to