Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/encodeous/nylon
/ Get
Method
Get
polyamide/device/pools.go:26–36 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
24
}
25
26
func
(p *WaitPool) Get() any {
27
if
p.max != 0 {
28
p.lock.Lock()
29
for
p.count >= p.max {
30
p.cond.Wait()
31
}
32
p.count++
33
p.lock.Unlock()
34
}
35
return
p.pool.Get()
36
}
37
38
func
(p *WaitPool) Put(x any) {
39
p.pool.Put(x)
Callers
14
TestWaitPool
Function · 0.95
BenchmarkWaitPool
Function · 0.95
BenchmarkWaitPoolEmpty
Function · 0.95
getMessages
Method · 0.45
Send
Method · 0.45
main
Function · 0.45
IpcGetOperation
Method · 0.45
GetInboundElementsContainer
Method · 0.45
GetOutboundElementsContainer
Method · 0.45
GetMessageBuffer
Method · 0.45
GetTCElement
Method · 0.45
GetInboundElement
Method · 0.45
Calls
1
Wait
Method · 0.45
Tested by
4
TestWaitPool
Function · 0.76
BenchmarkWaitPool
Function · 0.76
BenchmarkWaitPoolEmpty
Function · 0.76
BenchmarkSyncPool
Function · 0.36