Safe Haskell | None |
---|---|
Language | Haskell98 |
Input and Output for Chunked Flows.
Most functions in this module are re-exports of the ones from
Data.Repa.Flow.Generic.IO, but using the Sources
and Sinks
type synonyms for chunked flows.
- sourceRecords :: BulkI l Bucket => Integer -> (Word8 -> Bool) -> IO () -> Array l Bucket -> IO (Sources Int IO N (Array F Word8))
- sourceChars :: BulkI l Bucket => Integer -> Array l Bucket -> IO (Sources Int IO F Char)
- sourceBytes :: BulkI l Bucket => Integer -> Array l Bucket -> IO (Sources Int IO F Word8)
- sinkChars :: BulkI l Bucket => Array l Bucket -> IO (Sinks Int IO F Char)
- sinkBytes :: BulkI l Bucket => Array l Bucket -> IO (Sinks Int IO F Word8)
Sourcing
:: BulkI l Bucket | |
=> Integer | Size of chunk to read in bytes. |
-> (Word8 -> Bool) | Detect the end of a record. |
-> IO () | Action to perform if we can't get a whole record. |
-> Array l Bucket | File handles. |
-> IO (Sources Int IO N (Array F Word8)) |
Like fileSourceRecords
, but taking an existing file handle.
sourceChars :: BulkI l Bucket => Integer -> Array l Bucket -> IO (Sources Int IO F Char) Source #
Read 8-bit ASCII characters from some files, using the given chunk length.
sourceBytes :: BulkI l Bucket => Integer -> Array l Bucket -> IO (Sources Int IO F Word8) Source #
Read data from some files, using the given chunk length.