def __init__(self, id, acc): self.id = id self.acc = acc self.methods = [] ThreadSafeFinalizer.add_finalizer( id, ref(self, lambda wr, i=self.id, a=self.acc: deleted(a, i)))
def __init__(self, id, acc): self.id = id self.acc = acc self.methods = [] ThreadSafeFinalizer.add_finalizer( id, ref(self, lambda wr, i=self.id, a=self.acc: deleted(a, i)))
def __init__(self, target_id, gateway_client): """ :param target_id: the identifier of the object on the JVM side. Given by the JVM. :param gateway_client: the gateway client used to communicate with the JVM. """ # print(target_id + ' created.') self._target_id = target_id self._gateway_client = gateway_client self._auto_field = gateway_client.gateway_property.auto_field self._methods = {} key = smart_decode(self._gateway_client.address) +\ smart_decode(self._gateway_client.port) +\ self._target_id value = weakref.ref(self, lambda wr, cc=self._gateway_client, id=self._target_id: _garbage_collect_object(cc, id)) ThreadSafeFinalizer.add_finalizer(key, value)
def __init__(self, target_id, gateway_client): """ :param target_id: the identifier of the object on the JVM side. Given by the JVM. :param gateway_client: the gateway client used to communicate with the JVM. """ # print(target_id + ' created.') self._target_id = target_id self._gateway_client = gateway_client self._auto_field = gateway_client.gateway_property.auto_field self._methods = {} key = smart_decode(self._gateway_client.address) +\ smart_decode(self._gateway_client.port) +\ self._target_id value = weakref.ref(self, lambda wr, cc=self._gateway_client, id=self._target_id: _garbage_collect_object(cc, id)) ThreadSafeFinalizer.add_finalizer(key, value)