You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by jglynn43 <jg...@frontiernet.net> on 2009/03/08 00:34:40 UTC

Re: jaxb episode

I was seeing the same error.  The object was supposed to be an element but
xjc was parsing it as a type for some reason.  If you have the same type of
problem, you'll see the MessageTimestamp in your episode file like SCD
"tns:MessageTimestamp".  There's no '~' for elements.

My problem was I had defined elements that were just derived from types with
no extra attributes.  Xjc won't create any java bindings if the element
doesn't extend or restrict a type somehow.  I made them all extensions for
now, recompiled and everything worked.


Adrian C wrote:
> 
> have also tried passing in the epside as the jaxb binding
> 
> <java classname="org.apache.cxf.tools.wsdlto.WSDLToJava" fork="true">
>     <arg line="-b ${xjc.output}/sun-jaxb.episode"/>
> ...
> 
> but am still getting
> 
>   [java] WSDLToJava Error: Thrown by JAXB : SCD "~tns:MessageTimestamp"
> didnt match any schema component
>      [java] org.apache.cxf.tools.common.ToolException: Thrown by JAXB :
> SCD
> "~tns:MessageTimestamp" didnt match any schema component
>      [java] org.apache.cxf.tools.common.ToolException: Thrown by JAXB :
> SCD
> "~tns:MessageTimestamp" didnt match any schema component
> 
> 
> On Wed, Dec 10, 2008 at 11:13 AM, Adrian Corcoran
> <adrian.corcoran@gmail.com
>> wrote:
> 
>> I found out what my issue was, the params was incorrect - it should have
>> been:
>> <arg value="-xjc${output.dir}/xjc/ws-jaxb-beans.jar"/>
>>
>> However this is still not exactly working the way that I want it am
>> getting
>> errors:
>>
>>      [java] WSDLToJava Error: Thrown by JAXB : SCD
>> "~tns:MessageTimestamp"
>> didnt match any schema component
>>      [java] org.apache.cxf.tools.common.ToolException: Thrown by JAXB :
>> SCD
>> "~tns:MessageTimestamp" didnt match any schema component
>>
>> is there a way to just supply the episode file to wsdl2java like you can
>> for wsimport?
>>
>> https://jax-ws.dev.java.net/guide/Compiling_multiple_WSDLs_that_share_the_common_schema.html
>>
>> Thanks,
>>  Adrian
>>
>>
>> On Tue, Dec 9, 2008 at 8:00 PM, Adrian C
>> <ad...@gmail.com>wrote:
>>
>>>
>>> Hi,
>>>
>>> I am trying to use wsdl2java and trying to pass in a reference to a jaxb
>>> epsisode file so that the source is not regenerated (my wsdls are based
>>> on
>>> schemas that are already compile by jaxb). I am using the -xjc
>>> <existing-jaxb.jar> as part of my wsdl2java task but it seems to be
>>> ignored.
>>> My episode is defined as META-INF\sun-jaxb.episode in my jar - however
>>> wsdl2java seems to ignore the episode.
>>>
>>> Has anyone had problems with this? Anyone have a solution?
>>>
>>> Thanks,
>>> Adrian
>>> --
>>> View this message in context:
>>> http://www.nabble.com/jaxb-episode-tp20922242p20922242.html
>>> Sent from the cxf-user mailing list archive at Nabble.com.
>>>
>>>
>>
> 
> 

-- 
View this message in context: http://www.nabble.com/jaxb-episode-tp20922242p22393137.html
Sent from the cxf-user mailing list archive at Nabble.com.