Thanks Justin, I find it !
My mistake is to do a jaxws:bindings on element... We have to do a
jaxws:bindings on schema and after a
jaxb:bindings on element.. and It's work without jaxb version attribut...
like that :
<jaxws:bindings
node="wsdl:definitions/wsdl:types/xs:sche...@targetnamespace='theNamespace']">
<jxb:schemaBindings>
<jxb:package name="package.name" />
</jxb:schemaBindings>
<jxb:bindings node="//xs:eleme...@name='ELEM_NAME_1']">
<jxb:class name="ElemName1"/>
</jxb:bindings>
<jxb:bindings node="//xs:eleme...@name='ELEM_NAME_2']">
<jxb:class name="ElemName2"/>
</jxb:bindings>
</jaxws:bindings>
And I find an good example in jaxws.xsd :/
I hope this message can help other people :)
Samuel
jdmichal wrote:
>
> Just to be clear: Where are you introducing the 'version' element? The
> fact that the first two work OK leads me to think it should probably be on
> the schemaBindings element, or it's parent. Try those and see how it goes?
>
> Also, I'm not really too familiar with the use of elementName. When I
> wanted to do a similar task in a JAXB binding file (naming a generated
> type to a particular class name), mine looked like this:
>
> <jaxb:bindings node="xsd:eleme...@name='info']/xsd:complexType">
> <jaxb:class name="InfoType"/>
> </jaxb:bindings>
>
> Maybe you can try using jaxb:class inside the schemaBinding instead and
> see what happens?
>
> ~Justin
>
>
>
--
View this message in context:
http://www.nabble.com/WSDL2Java-and-jaxb-binding-for-element-tp24588503p24620511.html
Sent from the cxf-user mailing list archive at Nabble.com.