| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Hasql.Streams
Synopsis
- type CursorStreamFold s a r = forall x. (x -> CursorTransactionIO s (Maybe (a, x))) -> CursorTransactionIO s x -> r
- cursorStreamQuery :: forall params s a r. Statement params [a] -> params -> CursorStreamFold s a r -> r
Documentation
type CursorStreamFold s a r = forall x. (x -> CursorTransactionIO s (Maybe (a, x))) -> CursorTransactionIO s x -> r Source #
A fold over a stream of a values to produce an r using CursorTransactionIO s
cursorStreamQuery :: forall params s a r. Statement params [a] -> params -> CursorStreamFold s a r -> r Source #
Run a Statement using a cursor inside a CursorTransactionIO to produce a stream of as, which are consumed by a CursorStreamFold. This function can produce any type of stream without depending on any particular stream library.