Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/MultithreadedJSBook/code-samples
/ functions
Functions
82 in github.com/MultithreadedJSBook/code-samples
⨍
Functions
82
◇
Types & classes
19
↓ 11 callers
Method
write
(data /*: Uint8Array */)
ch6-ring-buffer/ring-buffer.js:31
↓ 4 callers
Method
exec
(method, ...args)
ch2-patterns/rpc-worker.js:17
↓ 4 callers
Function
setBool
(slot, value)
ch4-serialization/booleans.js:3
↓ 3 callers
Method
exec
(fn)
ch6-mutex/mutex.js:29
↓ 3 callers
Function
getBool
(slot)
ch4-serialization/booleans.js:6
↓ 3 callers
Function
sleep
(ms)
ch2-patterns/worker.js:1
↓ 2 callers
Method
exec
(method, ...args)
ch6-actors/rpc-worker.js:35
↓ 2 callers
Method
read
(bytes)
ch6-ring-buffer/ring-buffer.js:60
↓ 1 callers
Method
acquire
()
ch6-mutex/mutex.js:14
↓ 1 callers
Function
asyncOnMessageWrap
(fn)
ch2-patterns/worker.js:3
↓ 1 callers
Function
asyncOnMessageWrap
(fn)
ch8-template-render/worker.js:4
↓ 1 callers
Function
asyncOnMessageWrap
(fn)
ch6-actors/worker.js:3
↓ 1 callers
Function
asyncOnMessageWrap
(fn)
ch6-thread-pool/worker.js:3
↓ 1 callers
Method
exec
(method, ...args)
ch8-template-render/rpc-worker.js:35
↓ 1 callers
Method
exec
(method, ...args)
ch6-thread-pool/rpc-worker.js:35
↓ 1 callers
Method
getCell
(x, y)
ch5-game-of-life/thread-gol.js:11
↓ 1 callers
Method
getCell
(x, y)
ch5-game-of-life/gol.js:11
↓ 1 callers
Method
getWorker
()
ch8-template-render/rpc-worker.js:45
↓ 1 callers
Method
getWorker
()
ch6-actors/rpc-worker.js:45
↓ 1 callers
Method
getWorker
()
ch6-thread-pool/rpc-worker.js:45
↓ 1 callers
Function
isHappy
(num: u64)
ch7-happycoin-as/happycoin.ts:20
↓ 1 callers
Function
isHappy
(num)
ch3-happycoin/happycoin-piscina.js:20
↓ 1 callers
Function
isHappy
(num)
ch3-happycoin/happycoin-threads.js:24
↓ 1 callers
Function
isHappy
(num)
ch3-happycoin/happycoin.js:19
↓ 1 callers
Function
isHappycoin
(num: u64)
ch7-happycoin-as/happycoin.ts:27
↓ 1 callers
Function
isHappycoin
(num)
ch3-happycoin/happycoin-piscina.js:27
↓ 1 callers
Function
isHappycoin
(num)
ch3-happycoin/happycoin-threads.js:31
↓ 1 callers
Function
isHappycoin
(num)
ch3-happycoin/happycoin.js:26
↓ 1 callers
Function
is_happy
ch1-c-threads/happycoin-threads.c:32
↓ 1 callers
Function
is_happy
ch1-c-threads/happycoin.c:26
↓ 1 callers
Function
is_happycoin
ch1-c-threads/happycoin-threads.c:39
↓ 1 callers
Function
is_happycoin
ch1-c-threads/happycoin.c:33
↓ 1 callers
Function
iterate
(...args)
ch5-game-of-life/gol.js:73
↓ 1 callers
Method
iterate
(minX, minY, maxX, maxY)
ch5-game-of-life/thread-gol.js:23
↓ 1 callers
Method
iterate
(minX, minY, maxX, maxY)
ch5-game-of-life/gol.js:23
↓ 1 callers
Method
onMessageHandler
(msg, worker_id)
ch8-template-render/rpc-worker.js:26
↓ 1 callers
Method
onMessageHandler
(msg, worker_id)
ch6-actors/rpc-worker.js:26
↓ 1 callers
Method
onMessageHandler
(msg, worker_id)
ch6-thread-pool/rpc-worker.js:26
↓ 1 callers
Function
paint
(cell, x, y)
ch5-game-of-life/gol.js:57
↓ 1 callers
Function
random64
()
ch7-happycoin-as/happycoin.ts:5
↓ 1 callers
Function
random64
()
ch3-happycoin/happycoin-piscina.js:5
↓ 1 callers
Function
random64
()
ch3-happycoin/happycoin-threads.js:9
↓ 1 callers
Function
random64
()
ch3-happycoin/happycoin.js:4
↓ 1 callers
Function
random64
ch1-c-threads/happycoin-threads.c:13
↓ 1 callers
Function
random64
ch1-c-threads/happycoin.c:7
↓ 1 callers
Function
randomActor
()
ch6-actors/server.js:49
↓ 1 callers
Method
release
()
ch6-mutex/mutex.js:22
↓ 1 callers
Function
runCoord
()
ch5-game-of-life/thread-gol.js:139
↓ 1 callers
Function
runWorker
({ range, i })
ch5-game-of-life/thread-gol.js:129
↓ 1 callers
Function
sumDigitsSquared
(num: u64)
ch7-happycoin-as/happycoin.ts:10
↓ 1 callers
Function
sumDigitsSquared
(num)
ch3-happycoin/happycoin-piscina.js:10
↓ 1 callers
Function
sumDigitsSquared
(num)
ch3-happycoin/happycoin-threads.js:14
↓ 1 callers
Function
sumDigitsSquared
(num)
ch3-happycoin/happycoin.js:9
↓ 1 callers
Function
sum_digits_squared
ch1-c-threads/happycoin-threads.c:22
↓ 1 callers
Function
sum_digits_squared
ch1-c-threads/happycoin.c:16
Function
bad
()
ch2-patterns/worker.js:21
Method
constructor
(shared, index)
ch6-mutex/mutex.js:9
Method
constructor
(path)
ch2-patterns/rpc-worker.js:2
Method
constructor
(path, size = 0, strategy = 'roundrobin')
ch8-template-render/rpc-worker.js:6
Method
constructor
(size, buffer, paint = () => {})
ch5-game-of-life/thread-gol.js:2
Method
constructor
(size, buffer, paint = () => {})
ch5-game-of-life/gol.js:2
Method
constructor
(path, size = 0, strategy = 'roundrobin')
ch6-actors/rpc-worker.js:6
Method
constructor
(path, size = 0, strategy = 'roundrobin')
ch6-thread-pool/rpc-worker.js:6
Method
constructor
(meta/*: Uint32Array[3]*/, buffer /*: Uint8Array */)
ch6-ring-buffer/ring-buffer.js:2
Method
constructor
(shared/*: number | SharedArrayBuffer*/)
ch6-ring-buffer/ring-buffer.js:90
Function
fibonacci
(limit)
ch2-patterns/worker.js:15
Function
getHappycoins
(num: u32)
ch7-happycoin-as/happycoin.ts:31
Function
get_happycoins
ch1-c-threads/happycoin-threads.c:43
Function
handler
ch6-actors/server.js:15
Method
head
()
ch6-ring-buffer/ring-buffer.js:7
Function
initListener
(msg)
ch5-game-of-life/thread-gol.js:113
Method
length
()
ch6-ring-buffer/ring-buffer.js:23
Function
main
ch1-c-threads/happycoin-threads.c:65
Function
main
ch1-c-threads/happycoin.c:37
Function
makeRequest
()
ch2-service-workers/main.js:9
Method
onMessageHandler
(msg)
ch2-patterns/rpc-worker.js:9
Method
read
(bytes)
ch6-ring-buffer/ring-buffer.js:104
Function
square_sum
(max)
ch2-patterns/worker.js:10
Function
square_sum
(max)
ch6-actors/worker.js:10
Function
square_sum
(max)
ch6-thread-pool/worker.js:10
Method
tail
()
ch6-ring-buffer/ring-buffer.js:15
Method
write
(data)
ch6-ring-buffer/ring-buffer.js:100