data-accessor-0.2.2.8: Utilities for accessing and manipulating fields of records

Safe HaskellSafe
LanguageHaskell98

Data.Accessor.BinaryRead

Description

Reading records from streams

This is still only for demonstration and might be of not much use and you should not rely on the interface.

Documentation

type Stream = [Word8] Source #

class C a where Source #

Minimal complete definition

any

Methods

any :: ByteSource source => source a Source #

Instances
C Char Source # 
Instance details

Defined in Data.Accessor.BinaryRead

Methods

any :: ByteSource source => source Char Source #

C Int Source # 
Instance details

Defined in Data.Accessor.BinaryRead

Methods

any :: ByteSource source => source Int Source #

C Word8 Source # 
Instance details

Defined in Data.Accessor.BinaryRead

Methods

any :: ByteSource source => source Word8 Source #

class Monad source => ByteSource source where Source #

Minimal complete definition

readWord8

Methods

readWord8 :: source Word8 Source #

Instances
(ByteStream s, Monad m) => ByteSource (StateT s m) Source # 
Instance details

Defined in Data.Accessor.BinaryRead

Methods

readWord8 :: StateT s m Word8 Source #

class ByteStream s where Source #

Minimal complete definition

getWord8

Methods

getWord8 :: Monad m => s -> m (Word8, s) Source #

Instances
ByteCompatible byte => ByteStream [byte] Source # 
Instance details

Defined in Data.Accessor.BinaryRead

Methods

getWord8 :: Monad m => [byte] -> m (Word8, [byte]) Source #

class ByteCompatible byte where Source #

Minimal complete definition

toByte

Methods

toByte :: byte -> Word8 Source #

Instances
ByteCompatible Word8 Source # 
Instance details

Defined in Data.Accessor.BinaryRead

Methods

toByte :: Word8 -> Word8 Source #

newtype Parser s r Source #

Constructors

Parser 

Fields

field :: (ByteStream s, C a) => T r a -> Parser s r Source #

record :: [Parser s r] -> Parser s r Source #