cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Glen Mazza <glen.ma...@gmail.com>
Subject Java-first approach: Using JAXB objects generated from XSDs
Date Tue, 26 Oct 2010 12:36:03 GMT

Hello, I had earlier converted my WSDL-first tutorial[1] into a Java-first[2]
one but I'm missing how to include a schema so I can use JAXB-generated
objects for the requests and responses, and how to generate the JAXB objects
from the schema during the JavaToWS build process so those objects can be
used.

For the first part, I believe I can just manually add @WebResult and
@WebParam annotations to each method in the SEI, identifying the desired
JAXB-generated classes to use.  But how do I generate the JAXB objects from
the XSD?  With WSDL-first, I just need to incorporate (or include) the
necessary XSD's in the WSDL and the WSDL2Java process will use JAXB to
create the request/response objects.  But CXF's JavaToWS tool seems to lack
any command-line parameter to specify XSD's to generate the Java classes. 
Am I supposed to use JAXB as a separate step for that--I can do that, it
just seems strange for this process not to be already incorporated in the
JavaToWS process.

Thanks,
Glen

[1] http://www.jroller.com/gmazza/entry/web_service_tutorial
[2] http://www.jroller.com/gmazza/entry/java_first_web_service

-- 
View this message in context: http://cxf.547215.n5.nabble.com/Java-first-approach-Using-JAXB-objects-generated-from-XSDs-tp3236956p3236956.html
Sent from the cxf-user mailing list archive at Nabble.com.

Mime
View raw message