unliftio-0.2.25.0: The MonadUnliftIO typeclass for unlifting monads to IO (batteries included)

Safe Haskell | Safe-Inferred
Language | Haskell2010

UnliftIO.Chan

Description

Lifted Control.Concurrent.Chan.

Since: 0.1.0.0

Synopsis

- data Chan a
- newChan :: MonadIO m => m (Chan a)
- writeChan :: MonadIO m => Chan a -> a -> m ()
- readChan :: MonadIO m => Chan a -> m a
- dupChan :: MonadIO m => Chan a -> m (Chan a)
- getChanContents :: MonadIO m => Chan a -> m [a]
- writeList2Chan :: MonadIO m => Chan a -> [a] -> m ()

# Documentation

data Chan a #

`Chan` is an abstract type representing an unbounded FIFO channel.

#### Instances

Instances details

Eq (Chan a) | Since: base-4.4.0.0
Instance details Defined in Control.Concurrent.Chan Methods (==) :: Chan a -> Chan a -> Bool # (/=) :: Chan a -> Chan a -> Bool #

newChan :: MonadIO m => m (Chan a) #

Lifted `newChan`.

Since: 0.1.0.0

writeChan :: MonadIO m => Chan a -> a -> m () #

Lifted `writeChan`.

Since: 0.1.0.0

readChan :: MonadIO m => Chan a -> m a #

Lifted `readChan`.

Since: 0.1.0.0

dupChan :: MonadIO m => Chan a -> m (Chan a) #

Lifted `dupChan`.

Since: 0.1.0.0

getChanContents :: MonadIO m => Chan a -> m [a] #

Lifted `getChanContents`.

Since: 0.1.0.0

writeList2Chan :: MonadIO m => Chan a -> [a] -> m () #

Lifted `writeList2Chan`.

Since: 0.1.0.0