MCPcopy Index your code
hub / github.com/python/cpython / register

Method register

Lib/multiprocessing/resource_sharer.py:72–79  ·  view source on GitHub ↗

Register resource, returning an identifier.

(self, send, close)

Source from the content-addressed store, hash-verified

70 util.register_after_fork(self, _ResourceSharer._afterfork)
71
72 def register(self, send, close):
73 '''Register resource, returning an identifier.'''
74 with self._lock:
75 if self._address is None:
76 self._start()
77 self._key += 1
78 self._cache[self._key] = (send, close)
79 return (self._address, self._key)
80
81 @staticmethod
82 def get_connection(ident):

Callers 2

__init__Method · 0.45
__init__Method · 0.45

Calls 1

_startMethod · 0.95

Tested by

no test coverage detected