# Streaming IO

# Streaming IO

io-streams is Stream-based library that focuses on the Stream abstraction but for IO. It exposes two types:

  • `InputStream`: a read-only smart handle
  • `OutputStream`: a write-only smart handle
  • We can create a stream with makeInputStream :: IO (Maybe a) -> IO (InputStream a). Reading from a stream is performed using read :: InputStream a -> IO (Maybe a), where Nothing denotes an EOF: