Data.Iteratee.Binary

| iteratee-0.3.5: Iteratee-based I/O | Contents | Index
Data.Iteratee.Binary
Contents
Types Endian multi-byte iteratees
Description
Iteratees for parsing binary data.
Synopsis
data Endian
= MSB
| LSB
endianRead2 :: (StreamChunk s Word8, Monad m) => Endian -> IterateeG s Word8 m Word16
endianRead3 :: (StreamChunk s Word8, Monad m) => Endian -> IterateeG s Word8 m Word32
endianRead4 :: (StreamChunk s Word8, Monad m) => Endian -> IterateeG s Word8 m Word32
Types
data Endian
Indicate endian-ness.
Constructors
MSB | Most Significant Byte is first (big-endian)
LSB | Least Significan Byte is first (little-endian)
Instances
Enum Endian |
Eq Endian |
Ord Endian |
Show Endian |
Endian multi-byte iteratees
endianRead2 :: (StreamChunk s Word8, Monad m) => Endian -> IterateeG s Word8 m Word16
endianRead3 :: (StreamChunk s Word8, Monad m) => Endian -> IterateeG s Word8 m Word32
read 3 bytes in an endian manner. If the first bit is set (negative), set the entire first byte so the Word32 can be properly set negative as well.
endianRead4 :: (StreamChunk s Word8, Monad m) => Endian -> IterateeG s Word8 m Word32
Produced by Haddock version 2.7.2