module Blaze.ByteString.Builder.Int
(
writeInt8
, writeInt16be
, writeInt32be
, writeInt64be
, writeInt16le
, writeInt32le
, writeInt64le
, writeInthost
, writeInt16host
, writeInt32host
, writeInt64host
, fromInt8
, fromInt8s
, fromInt16be
, fromInt32be
, fromInt64be
, fromInt32sbe
, fromInt16sbe
, fromInt64sbe
, fromInt16le
, fromInt32le
, fromInt64le
, fromInt16sle
, fromInt32sle
, fromInt64sle
, fromInthost
, fromInt16host
, fromInt32host
, fromInt64host
, fromIntshost
, fromInt16shost
, fromInt32shost
, fromInt64shost
) where
import Data.Int
import Blaze.ByteString.Builder.Compat.Write ( Write, writePrimFixed )
import Data.ByteString.Builder ( Builder )
import qualified Data.ByteString.Builder as B
import qualified Data.ByteString.Builder.Extra as B
import qualified Data.ByteString.Builder.Prim as P
writeInt8 :: Int8 -> Write
writeInt8 :: Int8 -> Write
writeInt8 = FixedPrim Int8 -> Int8 -> Write
forall a. FixedPrim a -> a -> Write
writePrimFixed FixedPrim Int8
P.int8
{-# INLINE writeInt8 #-}
writeInt16be :: Int16 -> Write
writeInt16be :: Int16 -> Write
writeInt16be = FixedPrim Int16 -> Int16 -> Write
forall a. FixedPrim a -> a -> Write
writePrimFixed FixedPrim Int16
P.int16BE
{-# INLINE writeInt16be #-}
writeInt32be :: Int32 -> Write
writeInt32be :: Int32 -> Write
writeInt32be = FixedPrim Int32 -> Int32 -> Write
forall a. FixedPrim a -> a -> Write
writePrimFixed FixedPrim Int32
P.int32BE
{-# INLINE writeInt32be #-}
writeInt64be :: Int64 -> Write
writeInt64be :: Int64 -> Write
writeInt64be = FixedPrim Int64 -> Int64 -> Write
forall a. FixedPrim a -> a -> Write
writePrimFixed FixedPrim Int64
P.int64BE
{-# INLINE writeInt64be #-}
writeInt16le :: Int16 -> Write
writeInt16le :: Int16 -> Write
writeInt16le = FixedPrim Int16 -> Int16 -> Write
forall a. FixedPrim a -> a -> Write
writePrimFixed FixedPrim Int16
P.int16LE
{-# INLINE writeInt16le #-}
writeInt32le :: Int32 -> Write
writeInt32le :: Int32 -> Write
writeInt32le = FixedPrim Int32 -> Int32 -> Write
forall a. FixedPrim a -> a -> Write
writePrimFixed FixedPrim Int32
P.int32LE
{-# INLINE writeInt32le #-}
writeInt64le :: Int64 -> Write
writeInt64le :: Int64 -> Write
writeInt64le = FixedPrim Int64 -> Int64 -> Write
forall a. FixedPrim a -> a -> Write
writePrimFixed FixedPrim Int64
P.int64LE
{-# INLINE writeInt64le #-}
writeInthost :: Int -> Write
writeInthost :: Int -> Write
writeInthost = FixedPrim Int -> Int -> Write
forall a. FixedPrim a -> a -> Write
writePrimFixed FixedPrim Int
P.intHost
{-# INLINE writeInthost #-}
writeInt16host :: Int16 -> Write
writeInt16host :: Int16 -> Write
writeInt16host = FixedPrim Int16 -> Int16 -> Write
forall a. FixedPrim a -> a -> Write
writePrimFixed FixedPrim Int16
P.int16Host
{-# INLINE writeInt16host #-}
writeInt32host :: Int32 -> Write
writeInt32host :: Int32 -> Write
writeInt32host = FixedPrim Int32 -> Int32 -> Write
forall a. FixedPrim a -> a -> Write
writePrimFixed FixedPrim Int32
P.int32Host
{-# INLINE writeInt32host #-}
writeInt64host :: Int64 -> Write
writeInt64host :: Int64 -> Write
writeInt64host = FixedPrim Int64 -> Int64 -> Write
forall a. FixedPrim a -> a -> Write
writePrimFixed FixedPrim Int64
P.int64Host
{-# INLINE writeInt64host #-}
fromInt8 :: Int8 -> Builder
fromInt8 :: Int8 -> Builder
fromInt8 = Int8 -> Builder
B.int8
{-# INLINE fromInt8 #-}
fromInt8s :: [Int8] -> Builder
fromInt8s :: [Int8] -> Builder
fromInt8s = FixedPrim Int8 -> [Int8] -> Builder
forall a. FixedPrim a -> [a] -> Builder
P.primMapListFixed FixedPrim Int8
P.int8
{-# INLINE fromInt8s #-}
fromInt16be :: Int16 -> Builder
fromInt16be :: Int16 -> Builder
fromInt16be = Int16 -> Builder
B.int16BE
{-# INLINE fromInt16be #-}
fromInt32be :: Int32 -> Builder
fromInt32be :: Int32 -> Builder
fromInt32be = Int32 -> Builder
B.int32BE
{-# INLINE fromInt32be #-}
fromInt64be :: Int64 -> Builder
fromInt64be :: Int64 -> Builder
fromInt64be = Int64 -> Builder
B.int64BE
{-# INLINE fromInt64be #-}
fromInt32sbe :: [Int32] -> Builder
fromInt32sbe :: [Int32] -> Builder
fromInt32sbe = FixedPrim Int32 -> [Int32] -> Builder
forall a. FixedPrim a -> [a] -> Builder
P.primMapListFixed FixedPrim Int32
P.int32BE
{-# INLINE fromInt32sbe #-}
fromInt16sbe :: [Int16] -> Builder
fromInt16sbe :: [Int16] -> Builder
fromInt16sbe = FixedPrim Int16 -> [Int16] -> Builder
forall a. FixedPrim a -> [a] -> Builder
P.primMapListFixed FixedPrim Int16
P.int16BE
{-# INLINE fromInt16sbe #-}
fromInt64sbe :: [Int64] -> Builder
fromInt64sbe :: [Int64] -> Builder
fromInt64sbe = FixedPrim Int64 -> [Int64] -> Builder
forall a. FixedPrim a -> [a] -> Builder
P.primMapListFixed FixedPrim Int64
P.int64BE
{-# INLINE fromInt64sbe #-}
fromInt16le :: Int16 -> Builder
fromInt16le :: Int16 -> Builder
fromInt16le = Int16 -> Builder
B.int16LE
{-# INLINE fromInt16le #-}
fromInt32le :: Int32 -> Builder
fromInt32le :: Int32 -> Builder
fromInt32le = Int32 -> Builder
B.int32LE
{-# INLINE fromInt32le #-}
fromInt64le :: Int64 -> Builder
fromInt64le :: Int64 -> Builder
fromInt64le = Int64 -> Builder
B.int64LE
{-# INLINE fromInt64le #-}
fromInt16sle :: [Int16] -> Builder
fromInt16sle :: [Int16] -> Builder
fromInt16sle = FixedPrim Int16 -> [Int16] -> Builder
forall a. FixedPrim a -> [a] -> Builder
P.primMapListFixed FixedPrim Int16
P.int16LE
{-# INLINE fromInt16sle #-}
fromInt32sle :: [Int32] -> Builder
fromInt32sle :: [Int32] -> Builder
fromInt32sle = FixedPrim Int32 -> [Int32] -> Builder
forall a. FixedPrim a -> [a] -> Builder
P.primMapListFixed FixedPrim Int32
P.int32LE
{-# INLINE fromInt32sle #-}
fromInt64sle :: [Int64] -> Builder
fromInt64sle :: [Int64] -> Builder
fromInt64sle = FixedPrim Int64 -> [Int64] -> Builder
forall a. FixedPrim a -> [a] -> Builder
P.primMapListFixed FixedPrim Int64
P.int64LE
{-# INLINE fromInt64sle #-}
fromInthost :: Int -> Builder
fromInthost :: Int -> Builder
fromInthost = Int -> Builder
B.intHost
{-# INLINE fromInthost #-}
fromInt16host :: Int16 -> Builder
fromInt16host :: Int16 -> Builder
fromInt16host = Int16 -> Builder
B.int16Host
{-# INLINE fromInt16host #-}
fromInt32host :: Int32 -> Builder
fromInt32host :: Int32 -> Builder
fromInt32host = Int32 -> Builder
B.int32Host
{-# INLINE fromInt32host #-}
fromInt64host :: Int64 -> Builder
fromInt64host :: Int64 -> Builder
fromInt64host = Int64 -> Builder
B.int64Host
{-# INLINE fromInt64host #-}
fromIntshost :: [Int] -> Builder
fromIntshost :: [Int] -> Builder
fromIntshost = FixedPrim Int -> [Int] -> Builder
forall a. FixedPrim a -> [a] -> Builder
P.primMapListFixed FixedPrim Int
P.intHost
{-# INLINE fromIntshost #-}
fromInt16shost :: [Int16] -> Builder
fromInt16shost :: [Int16] -> Builder
fromInt16shost = FixedPrim Int16 -> [Int16] -> Builder
forall a. FixedPrim a -> [a] -> Builder
P.primMapListFixed FixedPrim Int16
P.int16Host
{-# INLINE fromInt16shost #-}
fromInt32shost :: [Int32] -> Builder
fromInt32shost :: [Int32] -> Builder
fromInt32shost = FixedPrim Int32 -> [Int32] -> Builder
forall a. FixedPrim a -> [a] -> Builder
P.primMapListFixed FixedPrim Int32
P.int32Host
{-# INLINE fromInt32shost #-}
fromInt64shost :: [Int64] -> Builder
fromInt64shost :: [Int64] -> Builder
fromInt64shost = FixedPrim Int64 -> [Int64] -> Builder
forall a. FixedPrim a -> [a] -> Builder
P.primMapListFixed FixedPrim Int64
P.int64Host
{-# INLINE fromInt64shost #-}