entwine-0.0.4: entwine - Concurrency tools
Entwine.Data.Gate
Contents
data Gate Source #
A gate is an abstract type, representing a simple barrier that can only have its state queried in a non-blocking manner.
This useful for implementing things like passing in a gate to terminate or stop a loop.
newGate :: IO Gate Source #
isOpen :: Gate -> IO Bool Source #
close :: Gate -> IO () Source #