Example #1
0
 def toPy(obj):
     if obj == ffi.NULL:
         return None
     # Python Objects can be returned without being wrapped in proxies
     py_handle = lib.get_handle_from_proxy_object_cw__foo_listener_bf(obj)
     if py_handle:
         assert py_handle in FooListenerBfHelper.c_data_set
         aux = ffi.from_handle(ffi.cast("void * ", py_handle))
         lib.foo_listener_bf___wrapper_dec_ref(obj)
         return aux
     return FooListenerBfCppProxy(obj)
Example #2
0
 def toPy(obj):
     if obj == ffi.NULL:
         return None
     # Python Objects can be returned without being wrapped in proxies
     py_handle = lib.get_handle_from_proxy_object_cw__foo_listener_bf(obj)
     if py_handle:
         assert py_handle in FooListenerBfHelper.c_data_set
         aux = ffi.from_handle(ffi.cast("void * ", py_handle))
         lib.foo_listener_bf___wrapper_dec_ref(obj)
         return aux
     return FooListenerBfCppProxy(obj)
Example #3
0
 def __del__(self):
     if not lib:
         return
     lib.foo_listener_bf___wrapper_dec_ref(self._cpp_impl)
Example #4
0
 def __del__(self):
     if not lib:
         return
     lib.foo_listener_bf___wrapper_dec_ref(self._cpp_impl)