This content has been marked as final.
Show 4 replies
-
1. Re: SOAPElement as input param
oskar.carlstedt Feb 6, 2008 3:59 PM (in response to cbax007)Hi!
Just use a javax.xml.ws.Provider< SOAPElement > provider. You create a class that implements the Provider interface. You'll get something like:@Local @Stateless @WebServiceProvider( serviceName = "...", portName = "...", targetNamespace = "...", wsdlLocation = "META-INF/wsdl/...") @ServiceMode(value = Service.Mode.PAYLOAD) public class MyServiceBean implements Provider<SOAPElement> { public SOAPElement invoke(SOAPElement requestSOAPElement) { ... } }
You can read more about this in the JBossWS documentation. Pay attention to the ServiceMode.PAYLOAD. If you change this to ServiceMode.MESSAGE you can retrieve the whole soap message.
You can only implement the javax.xml.ws.Provider with the types SOAPElement, SOAPMessage and Source (e.g. StreamSource, DOMSource, ...).
Cheers
/Oskar -
2. Re: SOAPElement as input param
heiko.braun Feb 7, 2008 3:41 AM (in response to cbax007)So, you figured it out yourself. Would you mind add some notes to the WIKI?
http://jbws.dyndns.org/mediawiki/index.php -
3. Re: SOAPElement as input param
cbax007 Feb 7, 2008 11:30 AM (in response to cbax007)Thanks for the help. I guess the one thing I'm fumbling with here is what the wsdl would look like for this service. In reading the docs, you need to include it explicitly with the deployed service as oppose to allowing it to be generated at deploy time. I tried to use wsprovide to generate it but that doesn't work. Could you provide a wsdl sample for the provider sample you included? Thanks.
-
4. Re: SOAPElement as input param
cbax007 Feb 7, 2008 11:57 AM (in response to cbax007)Nevermind. I figured it out. Thanks again for the help though.