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

Method Semaphore

Lib/multiprocessing/context.py:80–83  ·  view source on GitHub ↗

Returns a semaphore object

(self, value=1)

Source from the content-addressed store, hash-verified

78 return Condition(lock, ctx=self.get_context())
79
80 def Semaphore(self, value=1):
81 '''Returns a semaphore object'''
82 from .synchronize import Semaphore
83 return Semaphore(value, ctx=self.get_context())
84
85 def BoundedSemaphore(self, value=1):
86 '''Returns a bounded semaphore object'''

Callers 15

__init__Method · 0.80
test_semaphoreMethod · 0.80
test_timeoutMethod · 0.80
test_notifyMethod · 0.80
test_notify_allMethod · 0.80
test_notify_nMethod · 0.80
test_waitfor_timeoutMethod · 0.80
test_wait_integerMethod · 0.80
setUpMethod · 0.80
testWithSemaphoreMethod · 0.80

Calls 2

get_contextMethod · 0.95
SemaphoreClass · 0.70

Tested by 15

test_semaphoreMethod · 0.64
test_timeoutMethod · 0.64
test_notifyMethod · 0.64
test_notify_allMethod · 0.64
test_notify_nMethod · 0.64
test_waitfor_timeoutMethod · 0.64
test_wait_integerMethod · 0.64
setUpMethod · 0.64
testWithSemaphoreMethod · 0.64