iteratee-0.8.9.4: Iteratee-based I/O

Safe Haskell | Safe-Inferred

Data.Iteratee.Base.ReadableChunk

Description

Monadic Iteratees: incremental input parsers, processors and transformers

Support for IO enumerators

Synopsis

- class Storable el => ReadableChunk s el | s -> el where
  - readFromPtr :: MonadIO m => Ptr el -> Int -> m s

# Documentation

class Storable el => ReadableChunk s el | s -> el where

Class of streams which can be filled from a `Ptr`. Typically these are streams which can be read from a file, `Handle`, or similar resource.

Methods

readFromPtr

Arguments

:: MonadIO m |
=> Ptr el |
-> Int | The pointer must not be used after `readFromPtr` completes.
-> m s | The Int parameter is the length of the data in *bytes*.

Instances

ReadableChunk ByteString Word8 |
ReadableChunk ByteString Word8 |
ReadableChunk [Char] Char |
ReadableChunk [Word] Word |
ReadableChunk [Word8] Word8 |
ReadableChunk [Word16] Word16 |
ReadableChunk [Word32] Word32 |