[Haskell-cafe] ANNOUNCE: io-streams 1.0.0.0

13 views
Skip to first unread message

Gregory Collins

unread,
Mar 5, 2013, 5:07:39 PM3/5/13
to Haskell Cafe
Hi all,

After more than eight months of careful design and development, The Snap Framework team is happy to announce the first version of io-streams, a simple and easy-to-use library for doing streaming I/O in Haskell.

The io-streams library is based around two basic types, InputStream a and OutputStream a, and three fundamental I/O primitives:

-- read an item from an input stream
read :: InputStream a -> IO (Maybe a)
-- push an item back to an input stream
unRead :: a -> InputStream a -> IO ()
-- write to an output stream
write :: Maybe a -> OutputStream a -> IO ()

Streams can be transformed by composition and hooked together (using Kleisli composition) with a large set of provided combinators.

Simple types and operations in the IO monad mean straightforward and simple exception handling and resource cleanup using Haskell standard library functions like bracket.

The io-streams library comes with:
  • functions to use files, handles, concurrent channels, sockets, lists, vectors, and more as streams.
  • a plethora of combinators for wrapping and transforming streams, including compression and decompression using zlib, controlling precisely how many bytes are read from or written to a stream, buffering output using bytestring builders, folds, maps, filters, zips, etc.
  • support for parsing from streams using attoparsec.
For first-time users, io-streams comes with an included tutorial in theSystem.IO.Streams.Tutorial module, written by Gabriel Gonzalez of “pipes” fame.

The io-streams library is tested on GHC 7.0, 7.2, 7.4, and 7.6, and includes an extensive test suite with 100% function, statement, and branch coverage.

We would like to acknowledge the financial assistance of Erudify AG, who graciously funded some of the documentation and development of the io-streams library. Many thanks are also due to Gabriel Gonzalez, Andrew Cowie, Johan Tibell, and Bas van Dijk for their helpful discussions, contributions, and review.

For further details, you can read our release announcement here: http://snapframework.com/blog/2013/03/05/announcing-io-streams

Cheers,
G
--
Gregory Collins <gr...@gregorycollins.net>

s9gf4ult

unread,
Mar 5, 2013, 10:36:37 PM3/5/13
to haskel...@haskell.org
Is this something like conduits ?

_______________________________________________
Haskell-Cafe mailing list
Haskel...@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Erik de Castro Lopo

unread,
Mar 6, 2013, 12:10:10 AM3/6/13
to haskel...@haskell.org
s9gf4ult wrote:

> Is this something like conduits ?

Yes, its also a bit like Iteratee, Enumerator, Pipes and Machines.

Erik
--
----------------------------------------------------------------------
Erik de Castro Lopo
http://www.mega-nerd.com/

Alfredo Di Napoli

unread,
Mar 6, 2013, 3:08:20 AM3/6/13
to haskel...@haskell.org
As I've already said on Reddit,

awesome job guys. From the little I've seen the API is very lean and easy, so I'm really looking forward to playing with it and helping you with it as well :)

Bye,
Alfredo
Reply all
Reply to author
Forward
0 new messages