[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: State of ruby bindings?

From: Russell Yanofsky <rey4_at_columbia.edu>
Date: 2003-07-02 04:30:14 CEST

Kristian Hogsberg wrote:
> Garrett Rooney <rooneg@electricjellyfish.net> writes:
> Yeah, I realize the SWIG bindings are easier to maintain, but I looked
> at the python bindings and I wasn't too impressed. The subversion C
> API appears to be object-oriented C, in much the same way as the Gtk+
> toolkit, but the python bindings doesn't really reflect this. For
> example, the following code (from svnlook.py)
>
> txn_ptr = fs.open_txn(self.fs_ptr, txn, pool)
>
> should be (in my opinion, of course):
>
> txn_obj = fs_obj.open_txn(txn, pool)
>
> where the pointers are wrapped in python objects so you can say
> obj.method(args) instead of method(obj, args) as you would in C.

It's possible to use swig to make a more object oriented interface. See the
"Adding member functions to C structures" section of the swig documentation at
http://www.swig.org/Doc1.3/SWIG.html#n37 .

- Russ

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Jul 2 04:27:50 2003

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.