Correct me if I'm wrong but if you have _absolutely_ no clue on what the service's operations, parameters etc. is about or if the service returns a custom object (e.g. JavaBean) how can you use the getQuote example? I mean, how can you register the JavaBean on the client-side if you don't parse the WSDL yourself in the client application? Or how can you cast the return object to _anything_ if you don't find the return type in the WSDL document? And what about invoking a method on the returned bean (a getter) to get one of its fields? I would sure like to cut down on the amount of code I have (maintenance reasons obviously)
----- Original Message ----- Από: Tom Jordahl <[EMAIL PROTECTED]> Ημερομηνία: Τετάρτη, Μάρτιος 26, 2003 4:57μ.μ. Θέμα: RE: How to dynamically invoke a webservice provided just WSDL? > > Yes, this is exactly what the DII interface does - parse the WSDL > and build a Call object. We do the work so you don't have to! > > -- > Tom Jordahl > Macromedia Server Development > > -----Original Message----- > From: Doug Davis [mailto:[EMAIL PROTECTED] > Sent: Wednesday, March 26, 2003 8:50 AM > To: [EMAIL PROTECTED] > Subject: Re: How to dynamically invoke a webservice provided just > WSDL? > > > > > > I'm surprised you had to build up the Call object yourself. > If you look at the getQuote code in the stock quote sample (I > think its > getQuote2) he lets Axis parse the WSDL for him and Axis builds up the > Call object - no direct calls to wsdl4j. All you have to do is > tell it > which > operation you want. > -Dug > > <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] > > An identical situation still troubles me :) Anyway, my approach > was a > > bit more primitive than the getCalls method you're describing. I > wrote> a lot of code to parse the WSDL doc using classes in the > wsdl4j.jar> distributed along with axis (in \lib folder) and then > build up my Call > > object. In the end it works. If you're interested in this approach, > > you'll find very useful the following article in IBM's dW: > > "Dynamic Discovery and Invocation", by Damian Hagge (August 2001). > > It sure showed me the ropes. > > > > Regards, > > Costas > > > > > > >
