-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | Endian-sensitive data
--   
--   This package provides helpers for converting endian-sensitive data.
@package data-endian
@version 0.1.1

module Data.Endian

-- | Endianness.
data Endian

-- | Little-endian
LittleEndian :: Endian

-- | Big-endian
BigEndian :: Endian

-- | Return <a>True</a> if the supplied value is <a>LittleEndian</a>.
isLittleEndian :: Endian -> Bool

-- | Return <a>True</a> if the supplied value is <a>BigEndian</a>.
isBigEndian :: Endian -> Bool

-- | Raw, endian-sensitive data.
class EndianSensitive α

-- | Change the endianness of the argument.
swapEndian :: EndianSensitive α => α -> α

-- | Convert from the native format to little-endian.
toLittleEndian :: EndianSensitive α => α -> α

-- | Convert from little-endian to the native format.
fromLittleEndian :: EndianSensitive α => α -> α

-- | Convert from the native format to big-endian.
toBigEndian :: EndianSensitive α => α -> α

-- | Convert from big-endian to the native format.
fromBigEndian :: EndianSensitive α => α -> α

-- | Convert from the native format to the specified endianness.
toEndian :: EndianSensitive α => Endian -> α -> α

-- | Convert from the specified endianness to the native format.
fromEndian :: EndianSensitive α => Endian -> α -> α
instance GHC.Arr.Ix Data.Endian.Endian
instance GHC.Enum.Enum Data.Endian.Endian
instance GHC.Enum.Bounded Data.Endian.Endian
instance GHC.Classes.Ord Data.Endian.Endian
instance GHC.Classes.Eq Data.Endian.Endian
instance GHC.Generics.Generic Data.Endian.Endian
instance GHC.Read.Read Data.Endian.Endian
instance GHC.Show.Show Data.Endian.Endian
instance Data.Data.Data Data.Endian.Endian
instance Data.Endian.EndianSensitive α => Data.Endian.EndianSensitive [α]
instance Data.Endian.EndianSensitive GHC.Word.Word16
instance Data.Endian.EndianSensitive GHC.Word.Word32
instance Data.Endian.EndianSensitive GHC.Word.Word64
instance Data.Endian.EndianSensitive GHC.Int.Int16
instance Data.Endian.EndianSensitive GHC.Int.Int32
instance Data.Endian.EndianSensitive GHC.Int.Int64
instance Data.Endian.EndianSensitive Foreign.C.Types.CShort
instance Data.Endian.EndianSensitive Foreign.C.Types.CUShort
instance Data.Endian.EndianSensitive Foreign.C.Types.CInt
instance Data.Endian.EndianSensitive Foreign.C.Types.CUInt
instance Data.Endian.EndianSensitive Foreign.C.Types.CLong
instance Data.Endian.EndianSensitive Foreign.C.Types.CULong
instance Data.Endian.EndianSensitive Foreign.C.Types.CLLong
instance Data.Endian.EndianSensitive Foreign.C.Types.CULLong
instance Data.Endian.EndianSensitive Foreign.C.Types.CSize
instance Data.Endian.EndianSensitive System.Posix.Types.CSsize
instance Data.Endian.EndianSensitive Foreign.C.Types.CUIntPtr
instance Data.Endian.EndianSensitive Foreign.C.Types.CIntPtr
instance Data.Endian.EndianSensitive Foreign.C.Types.CPtrdiff
instance Data.Endian.EndianSensitive Foreign.C.Types.CUIntMax
instance Data.Endian.EndianSensitive Foreign.C.Types.CIntMax
instance Data.Endian.EndianSensitive Foreign.Ptr.WordPtr
instance Data.Endian.EndianSensitive Foreign.Ptr.IntPtr
instance Data.Endian.EndianSensitive Foreign.C.Types.CWchar
