Re: [PEPr] Comment on XML::XML_RPC2

From: Date: Sat, 06 Nov 2004 21:05:59 +0000
Subject: Re: [PEPr] Comment on XML::XML_RPC2
References: 1 2 3 4 5 6 7  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-34244@lists.php.net to get a copy of this message
Davey wrote:
My biggest issue is the class extending, for the simple reason that you need to extend different classes for SOAP/XML-RPC/REST and you can only extend *one*. So you need to write three different classes all of a sudden one that extends a class for each types introspection.
Not true. I can write for you a MethodHandler that can expose another class's methods. Then, imagine you want to expose the methods of class Foo: $foo = new Foo(); $server = new XML_RPC2_Server(new XML_RPC2_DelegationMethodHandler($foo));
Introspection should have no effects/changes on the code itself, it should be self contained. With that thought in mind, your ideas just won't work in that "one API fits all" strategy. We would need to write the introspection both for server and client completely independant of the web service. Now, I can modify *my* code to introspect to a WSDL-like data structure pretty easily (heck, right now it goes to WSDL and then is parsed into that data structure) which contains all the information needed: * Class Name * Method Names * Method Arguments * Method Return values * Documentation I've put in all the ground work already, for the most part at least. The fact that WSDL is XML, means its implementation non-specific, and therefore could be used as an internal representation for a web service.
I'm not very keen on using WSDL. It's a layer of complexity that presents no added value. WSDL really hasn't caught on in communities outside SOAP. Heck, it even lacks XML-RPC bindings. Can you justify the usage of WSDL. What do we gain, when compared to using a regular common API? Sérgio

« previous php.pear.dev (#34244) next »