[prev in list] [next in list] [prev in thread] [next in thread]
List: pykde
Subject: [PyKDE] boost::shared_ptr
From: James Emerton <james () emdata ! net>
Date: 2005-03-21 17:29:59
Message-ID: a0be814e649809e93bb089537e88d885 () emdata ! net
[Download RAW message or body]
I am rather new to PyQt/SIP and looking for a hint or two.
The application in which I am embedding Python has a fairly extensive
(non-Qt) API, with a Qt UI sitting on top. The API makes extensive use
of refcounted smart pointers (boost::shared_ptr) to abstract interface
classes.
So far, I believe that I can use the %MethodCode directive to override
factory methods, and dynamically allocate a new instance of the smart
pointer, which would increment the shared_ptr reference count and
prevent deletion so long as the python ref count was non zero. The
problem with this approach seems that I would also have to write
%MethodCode to access every method in the wrapped class!
Thanks
James
--
This is not my home; the cats just let me stay here.
_______________________________________________
PyKDE mailing list PyKDE@mats.imk.fraunhofer.de
http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic