Embedded C++, confused about the self pointer/init

Reagan reagan_laurence at hotmail.com
Wed Jan 29 17:50:49 EST 2003


I have an instance of a python class created in C++.  The problem is
that I don't understand why the __init__ is not receiving a self
pointer.  I want to set the instance of this class to an already
existing object so what I am having to do is instantiate the class,
then call a method I created to specifically set the self pointer to
be the reference to the already existing object.  Why am I not able to
do this in the __init__ method?  I want all of this to be done with
methods on the C++ side.  I am assuming that I can define the
'default' __init__ method in C++.

If this is clear as mud, I will post some code that we got to execute
correctly here at work and try to explain my confusion further (if
that makes any sense!)

Thanks!

Reagan

P.S.  Please bear with me as I am new to Python.




More information about the Python-list mailing list