[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Gnue-dev] Two GCommBase Questions
From: |
Jan Ischebeck |
Subject: |
Re: [Gnue-dev] Two GCommBase Questions |
Date: |
Tue, 21 May 2002 15:52:49 +0200 |
User-agent: |
Mutt/1.3.28i |
On Mon, May 20, 2002 at 08:03:58PM +0200, Harald Meyer wrote:
> Hi,
>
> looking at the source code of GCommBase.py, I found two things which
> kept me wondering:
>
> 1.) Line 167:
> __call__ calls the associated client adapter with it self as a method.
> I think I understand the principle:
> ProxyObjects not only stand for remote objects, but also for their
> methods. if a proxy object is called with an attribute(method) an proxy
> object for it is created (with __getattr__). Now the __call__ method
> emulates the calling of this method.
>
> What I don't understand is: runMethod expects a string, but self is a
> reference. Is the conversion done implictly, wenn the C-Code of
> py-rpcxml is called?
In case of the xmlrpc code there is no conversion. The __call__ method
is overridden in _ProxyObject(GCommBase.ProxyObject) [in ClientAdapter.py]
But you're right, it makes not much sense to pass a reference to an
object instead of a string, so I will move the function from
ClientAdapter._ProxyObject to GCommBase.ProxyObject.
>
> 2.) Lines 82 and 95:
> Why does Server have two exactly equal serveAsNewThread methods. I
> guess one would be enough. This doesn't do any harm, but I made a patch
> which removes one of the methods and sent it to address@hidden .
You're right this an error. I'll fix it.
Jan Ischebeck
J.I. e-Services
address@hidden