that's a pity, as it works for me.
On 11/12/06, [EMAIL PROTECTED] <
[EMAIL PROTECTED]> wrote:
Hi,
Thanks for your help.
I've already tried this but with no success. I read some posts about this
known problem.
Best regards
Christophe
*"Wayne Keenan" <[EMAIL PROTECTED]>*
08/12/2006 17:33
Veuillez répondre à user
Pour : [email protected]
cc :
Objet : Re: [xfire-user] [XMLBeans]How to customize WSDL
Generation without annotations
to specify a 'fixed' WSDL there is a <wsdlURL> parameter in the service
config.
<wsdlURL>*file:///location/of/wsdl*</wsdlURL>
*
**http://xfire.codehaus.org/services.xml+Reference*<http://xfire.codehaus.org/services.xml+Reference>
On 08/12/06, [EMAIL PROTECTED]<[EMAIL PROTECTED]><
[EMAIL PROTECTED] <[EMAIL PROTECTED]>>
wrote:
Hi,
Thanks for your help.
I will try this soon.
As a work-around, I've created a WebServiceController class extending
XFireExporter. When the request.getQueryString() return "wsdl" or "WSDL" I
simply return the URL of a static WSDL file included in my web service.
Otherwise, I return control to parent class. Then, it works perfectly.
Here is the code sample :
package com.geopost.clp.cityssimo.wsapi.controller;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.codehaus.xfire.spring.remoting.XFireExporter;
import org.springframework.web.servlet.ModelAndView;
public class WebServiceController extends XFireExporter {
/* (non-Javadoc)
* @see
org.codehaus.xfire.spring.remoting.XFireExporter#handleRequest(
javax.servlet.http.HttpServletRequest,
javax.servlet.http.HttpServletResponse)
*/
public ModelAndView handleRequest(HttpServletRequest request,
HttpServletResponse response) throws Exception {
ModelAndView returnModelAndView = null;
if ( "wsdl".equalsIgnoreCase(request.getQueryString())) {
returnModelAndView = new
ModelAndView("/WEB-INF/classes/META-INF/myWsdlFile.wsdl");
} else {
returnModelAndView = super.handleRequest(request,
response);
}
return returnModelAndView;
}
}
Christophe
*"Dan Diephouse" <[EMAIL PROTECTED] <[EMAIL PROTECTED]>*> *
08/12/2006 17:05
Veuillez répondre à user
Pour : [EMAIL PROTECTED] <[email protected]>
cc :
Objet : Re: [xfire-user] [XMLBeans]How to customize WSDL
Generation without annotations
Hi Christophe,
You could look into the WSDLBuilder code in XFire. It allows you to
specify a WSDLBuilderExtension which can customize the WSDL. That will only
change the WSDL though, if that doesn't map to your service class and how
XFire expects the mapping to be, I'm not sure it will work.
I think you'd use it something like this:
XFire xfire = XFireFactory.newInstance().getXFire();
Service service = getServiceRegistry().getService("myservice")
wsdlBuilder = new WSDLBuilder(service, xfire.getTransportManager());
WSDLBuilderExtension myExtension = ...;
List exts = new ArrayList();
exts.add(myExtension);
wsdlBuilder.setExtensions(exts);
That kind of requires a little bit of knowledge of the XFire APIs though.
Hope that helps,
- Dan
On 12/6/06, [EMAIL PROTECTED] *<[EMAIL PROTECTED]>
<[EMAIL PROTECTED] * <[EMAIL PROTECTED]>>
wrote:
Hi,
Is there any way to customize the WSDL generation in a XMLBeans-based Web
service ?
I know this kind of customization can be achieved by using JSR181
annotations, but I don't want to use it (because the project can't be
refactored now).
Is there any other way ?
Thanks in advance
PS: I use XFire1.2.1 and Spring 2.0 together on a jdk 1.4 platform.
Christophe
--
Dan Diephouse
Envoi Solutions*
**http://envoisolutions.com* <http://envoisolutions.com/> | *
http://netzooid.com/blog* <http://netzooid.com/blog>