Here's an idea.

1) Take your interface/implementation class and run it through Java2WSDL to
create a wsdl file.
2) Take the wsdl file and run WSDL2Java to generate the client and server
side stubs/skeletons.
3) Study the stubs and skeletons...

A couple of things that I do know:
a) The Axis runtime wraps primitives during the serialization and
deserialization process.   The
conversion stubs and deserialization runtime convert from the wrapped
obects into the primitives if necessary.
b) The Axis runtime support for overloading is in it infancy.  If you are
depending on int or Integer
to determine overloaded resolution you may run into problems.


Hope this help.  You may want to also look at the samples.echo.TestClient
code "echoInteger" invoke.

Rich Scheuerle
XML & Web Services Development
512-838-5115  (IBM TL 678-5115)


                                                                                       
                                          
                      Frank Griffin                                                    
                                          
                      <[EMAIL PROTECTED]        To:       axis-user 
<[EMAIL PROTECTED]>                                    
                      r.com>                   cc:                                     
                                          
                      Sent by:                 Subject:  SOAP and Java Reference 
Classes                                         
                      [EMAIL PROTECTED]                                                   
                                          
                                                                                       
                                          
                                                                                       
                                          
                      02/15/2002 09:23                                                 
                                          
                      AM                                                               
                                          
                      Please respond to                                                
                                          
                      axis-user                                                        
                                          
                                                                                       
                                          
                                                                                       
                                          



Could someone tell me how Axis and SOAP deal with  Java primitives and
the associated Reference Types ?

In other words, if I have two server-side methods, one of which takes a
Long parameter and returns a Long result, and the other of which takes a
long parameter and returns a long result, does the SOAP client see any
difference or does it only support the primitive and is Axis quietly
converting the parameters and returns from my methods ?

I'm trying to code a server-side SOAP class which can be used to invoke
methods on arbitrary EJBs, by exposing to SOAP clients a single invoke()
method, very much like Proxy/InvocationHandler.  This means that the
parameters and returns for this method will be Objects, regardless of
whether the associated parameters/returns for the EJB in question are
primitives.

If the SOAP client has no knowledge of Java Reference classes and deals
only in primitives, then is it the responsibility of a Java server-side
implementation to convert his primitive references to reference objects
(and vice-versa) as needed ?

What I'm trying to determine is whether I can get away with telling
SOAP clients to use the same call signatures documented in the
API Javadoc for the EJB, even though my invoke() method will be dealing
with reference objects in place of primitives.  Java Proxy and
Method.invoke() will handle this OK, but I don't know what Axis will do
with the Objects I expect as parameters or return as returns.

TIA,
Frank




Reply via email to