observable signal channels
Go to file
mleku fa98655f42
updating to new domain
2024-02-18 21:16:16 +00:00
.gitignore update domain 2024-02-18 20:58:54 +00:00
LICENSE Initial commit 2023-11-24 09:43:37 +00:00
README.md some small fixes to README.md 2023-11-26 09:13:45 +00:00
go.mod updating to new domain 2024-02-18 21:16:16 +00:00
go.sum updating to new domain 2024-02-18 21:16:16 +00:00
qu.go update domain 2024-02-18 20:58:54 +00:00

README.md

qu

observable signal channels

simple channels that act as breakers or momentary one-shot triggers.

can enable logging to get detailed information on channel state, and channels do not panic if closed channels are attempted to be closed or signalled with.

provides a neat function based syntax for usage.

wait function does require use of the <- receive operator prefix to be used in a select statement.

usage

creating channels:

unbuffered

newSigChan := qu.T()

buffered

newBufferedSigChan := qu.Ts(5)

closing

newSigChan.Q()

signalling

newBufferedSigChan.Signal()

logging features

numberOpenUnbufferedChannels := GetOpenUnbufferedChanCount()

numberOpenBufferedChannels := GetOpenBufferedChanCount()

print a list of closed and open channels known by qu:

PrintChanState() 

garbage collection

this library automatically cleans up closed channels once a minute to free resources that have become unused.