If you're not supposed to use wsdl2java to create client stubs, then
you should use the call interface. But if you're using complex types,
it's really difficult to make it work because Axis can't just
arbitrarily map XML structures into Java types. It needs to have value
objects that corresponds to the XML types.

Axis also supports dynamic proxies, in which java2wsdl generates
interfaces, and the proxy implementations are generated at runtime
based on binding parameters. That way you have the generated value
objects, and you also have flexible binding.

If you don't use wsdl2java and you're using complex types, then you
may have to process the XML messages programmatically using DOM.
According to the JAX-RPC spec, any unknown type is supposed to be
returned as a SOAPElement, but I don't think that's how Axis works. It
typically throws and exception saying that it doesn't have the proper
deserializer for the type.

One way to get around the type mapping issues is to use a loosely
typed programming language on the client, such as Python...

Anne

On 6/3/05, Ravi Krishnamurthy <[EMAIL PROTECTED]> wrote:
> Thanks Anne for your reply.
> 
> Basically I'm trying to develop a client to webservice. So I need to map
> the client inputs to the webservice request and return the response in
> client understandable format. I wanted to avoid generation of classes
> using WSDL2JAVA if possible since it is not recommended in my project.
> Also I dont know what webservice are called because each client needs to
> configure their webservice details.
> 
> I have some additional questions. I'm new to webservice.
> 1. How did you say the WSDL I sent conforms to wrapped convention
> because I see the style.use as document/literal.
> 2. I thought I saw the WSDL2JAVA also generated the classes for anyType.
> I did not write any deserializers. Guess you meant writing deserializers
> if I dont use WSDL2JAVA?
> 3. Where can I find some example of serializer/deserializer
> Thanks,
> Ravi
> 
> Anne Thomas Manes wrote:
> 
> >The service is defined as document/literal, therefore that's how you
> >must encode the messages. But you can still "invoke" it using an RPC
> >style -- at least from your application's perspective. This WSDL
> >conforms to the "wrapped" convention, so Axis allows you to invoke it
> >using an RPC programming style.
> >
> >The right way to do that is to use WSDL2Java to generate a client
> >proxy stub and to invoke methods on the stub. Because the service uses
> >anyType, you also need to define custom deserializers.
> >
> >What exactly are you looking to do?
> >
> >Anne
> >
> >On 6/2/05, Ravi Krishnamurthy <[EMAIL PROTECTED]> wrote:
> >
> >
> >>Hello:
> >>I 'm a newbie to Axis. Was looking into the following wsdl:
> >>http://www.atomic-x.com/xmlservices/dnslookupservice.asmx?wsdl
> >>
> >>Was able to use WSDL2JAVA from Axis to generate the stubs and hence invoke 
> >>the
> >>webservice.
> >>
> >>Wondering is there any other way to invoke the webservice successfully
> >>instead of using WSDL2JAVA. The webservices has datatypes that could be 
> >>complex types and would like to invoke RPC as well as Document style.
> >>
> >>I'm looking only as a client to invoke the webservices. Also any 
> >>suggestions design approach for this is welcome.
> >>
> >>Thanks for your time.
> >>Regards,
> >>Ravi
> >>
> >>
> >>
> >>
> >>
> 
> 
>

Reply via email to