storable-endian-0.2.6.1: Storable instances with endianness
Copyright(c) Eugene Kirpichov 2010
LicenseNew BSD
MaintainerEugene Kirpichov <ekirpichov@gmail.com>
Stabilityexperimental
Portabilityportable
Safe HaskellNone
LanguageHaskell98

Data.Storable.Endian

Description

Storable instances with endianness.

Documentation

newtype LittleEndian a Source #

Constructors

LE 

Fields

Instances

Instances details
Enum a => Enum (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Eq a => Eq (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Floating a => Floating (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Fractional a => Fractional (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Integral a => Integral (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Num a => Num (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Ord a => Ord (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Read a => Read (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Real a => Real (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

RealFloat a => RealFloat (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

RealFrac a => RealFrac (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Show a => Show (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Generic (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Associated Types

type Rep (LittleEndian a) :: Type -> Type #

Methods

from :: LittleEndian a -> Rep (LittleEndian a) x #

to :: Rep (LittleEndian a) x -> LittleEndian a #

(HasLittleEndian a, Storable a) => Storable (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

type Rep (LittleEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

type Rep (LittleEndian a) = D1 ('MetaData "LittleEndian" "Data.Storable.Endian" "storable-endian-0.2.6.1-5yvaWU1ZEUp651cNKK37lg" 'True) (C1 ('MetaCons "LE" 'PrefixI 'True) (S1 ('MetaSel ('Just "getLittleEndian") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 a)))

newtype BigEndian a Source #

Constructors

BE 

Fields

Instances

Instances details
Enum a => Enum (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Eq a => Eq (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Methods

(==) :: BigEndian a -> BigEndian a -> Bool #

(/=) :: BigEndian a -> BigEndian a -> Bool #

Floating a => Floating (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Fractional a => Fractional (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Integral a => Integral (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Num a => Num (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Ord a => Ord (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Read a => Read (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Real a => Real (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

RealFloat a => RealFloat (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

RealFrac a => RealFrac (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Methods

properFraction :: Integral b => BigEndian a -> (b, BigEndian a) #

truncate :: Integral b => BigEndian a -> b #

round :: Integral b => BigEndian a -> b #

ceiling :: Integral b => BigEndian a -> b #

floor :: Integral b => BigEndian a -> b #

Show a => Show (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Generic (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Associated Types

type Rep (BigEndian a) :: Type -> Type #

Methods

from :: BigEndian a -> Rep (BigEndian a) x #

to :: Rep (BigEndian a) x -> BigEndian a #

(HasBigEndian a, Storable a) => Storable (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

Methods

sizeOf :: BigEndian a -> Int #

alignment :: BigEndian a -> Int #

peekElemOff :: Ptr (BigEndian a) -> Int -> IO (BigEndian a) #

pokeElemOff :: Ptr (BigEndian a) -> Int -> BigEndian a -> IO () #

peekByteOff :: Ptr b -> Int -> IO (BigEndian a) #

pokeByteOff :: Ptr b -> Int -> BigEndian a -> IO () #

peek :: Ptr (BigEndian a) -> IO (BigEndian a) #

poke :: Ptr (BigEndian a) -> BigEndian a -> IO () #

type Rep (BigEndian a) Source # 
Instance details

Defined in Data.Storable.Endian

type Rep (BigEndian a) = D1 ('MetaData "BigEndian" "Data.Storable.Endian" "storable-endian-0.2.6.1-5yvaWU1ZEUp651cNKK37lg" 'True) (C1 ('MetaCons "BE" 'PrefixI 'True) (S1 ('MetaSel ('Just "getBigEndian") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 a)))

class HasLittleEndian a where Source #

Methods

peekLE :: Ptr a -> IO a Source #

pokeLE :: Ptr a -> a -> IO () Source #

Instances

Instances details
HasLittleEndian Double Source # 
Instance details

Defined in Data.Storable.Endian

HasLittleEndian Float Source # 
Instance details

Defined in Data.Storable.Endian

HasLittleEndian Int16 Source # 
Instance details

Defined in Data.Storable.Endian

HasLittleEndian Int32 Source # 
Instance details

Defined in Data.Storable.Endian

HasLittleEndian Int64 Source # 
Instance details

Defined in Data.Storable.Endian

HasLittleEndian Word16 Source # 
Instance details

Defined in Data.Storable.Endian

HasLittleEndian Word32 Source # 
Instance details

Defined in Data.Storable.Endian

HasLittleEndian Word64 Source # 
Instance details

Defined in Data.Storable.Endian

class HasBigEndian a where Source #

Methods

peekBE :: Ptr a -> IO a Source #

pokeBE :: Ptr a -> a -> IO () Source #

Instances

Instances details
HasBigEndian Double Source # 
Instance details

Defined in Data.Storable.Endian

HasBigEndian Float Source # 
Instance details

Defined in Data.Storable.Endian

HasBigEndian Int16 Source # 
Instance details

Defined in Data.Storable.Endian

HasBigEndian Int32 Source # 
Instance details

Defined in Data.Storable.Endian

HasBigEndian Int64 Source # 
Instance details

Defined in Data.Storable.Endian

HasBigEndian Word16 Source # 
Instance details

Defined in Data.Storable.Endian

HasBigEndian Word32 Source # 
Instance details

Defined in Data.Storable.Endian

HasBigEndian Word64 Source # 
Instance details

Defined in Data.Storable.Endian