rio-0.1.4.0: A standard library for Haskell

Safe HaskellNone
LanguageHaskell2010

RIO.ByteString.Lazy

Contents

Description

Lazy ByteString. Import as:

import qualified RIO.ByteString.Lazy as BL
Synopsis

The ByteString type

data ByteString #

Instances
Eq ByteString 
Instance details

Defined in Data.ByteString.Lazy.Internal

Data ByteString 
Instance details

Defined in Data.ByteString.Lazy.Internal

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ByteString -> c ByteString #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ByteString #

toConstr :: ByteString -> Constr #

dataTypeOf :: ByteString -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c ByteString) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ByteString) #

gmapT :: (forall b. Data b => b -> b) -> ByteString -> ByteString #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ByteString -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ByteString -> r #

gmapQ :: (forall d. Data d => d -> u) -> ByteString -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> ByteString -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> ByteString -> m ByteString #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> ByteString -> m ByteString #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> ByteString -> m ByteString #

Ord ByteString 
Instance details

Defined in Data.ByteString.Lazy.Internal

Read ByteString 
Instance details

Defined in Data.ByteString.Lazy.Internal

Methods

readsPrec :: Int -> ReadS ByteString

readList :: ReadS [ByteString]

readPrec :: ReadPrec ByteString

readListPrec :: ReadPrec [ByteString]

Show ByteString 
Instance details

Defined in Data.ByteString.Lazy.Internal

Methods

showsPrec :: Int -> ByteString -> ShowS

show :: ByteString -> String #

showList :: [ByteString] -> ShowS

IsString ByteString 
Instance details

Defined in Data.ByteString.Lazy.Internal

Semigroup ByteString 
Instance details

Defined in Data.ByteString.Lazy.Internal

Monoid ByteString 
Instance details

Defined in Data.ByteString.Lazy.Internal

NFData ByteString 
Instance details

Defined in Data.ByteString.Lazy.Internal

Methods

rnf :: ByteString -> () #

Hashable ByteString 
Instance details

Defined in Data.Hashable.Class

Introducing and eliminating ByteStrings

foldrChunks :: (ByteString -> a -> a) -> a -> ByteString -> a #

foldlChunks :: (a -> ByteString -> a) -> a -> ByteString -> a #

Basic interface

Transforming ByteStrings

Reducing ByteStrings (folds)

foldl :: (a -> Word8 -> a) -> a -> ByteString -> a #

foldl' :: (a -> Word8 -> a) -> a -> ByteString -> a #

foldr :: (Word8 -> a -> a) -> a -> ByteString -> a #

Special folds

any :: (Word8 -> Bool) -> ByteString -> Bool #

all :: (Word8 -> Bool) -> ByteString -> Bool #

Building ByteStrings

Scans

Accumulating maps

mapAccumL :: (acc -> Word8 -> (acc, Word8)) -> acc -> ByteString -> (acc, ByteString) #

mapAccumR :: (acc -> Word8 -> (acc, Word8)) -> acc -> ByteString -> (acc, ByteString) #

Infinite ByteStrings

Unfolding ByteStrings

unfoldr :: (a -> Maybe (Word8, a)) -> a -> ByteString #

Substrings

Breaking strings

Breaking into many substrings

Predicates

Search ByteStrings

Searching by equality

Searching with a predicate

Indexing ByteStrings

Zipping and unzipping ByteStrings

zipWith :: (Word8 -> Word8 -> a) -> ByteString -> ByteString -> [a] #

Low level conversions

Copying ByteStrings

I/O with ByteStrings

Standard input and output

getContents :: MonadIO m => m LByteString Source #

Lifted getContents

putStr :: MonadIO m => LByteString -> m () Source #

Lifted putStr

putStrLn :: MonadIO m => LByteString -> m () Source #

Lifted putStrLn

interact :: MonadIO m => (LByteString -> LByteString) -> m () Source #

Lifted interact

Files

readFile :: MonadIO m => FilePath -> m LByteString Source #

Lifted readFile

writeFile :: MonadIO m => FilePath -> LByteString -> m () Source #

Lifted writeFile

appendFile :: MonadIO m => FilePath -> LByteString -> m () Source #

Lifted appendFile

I/O with Handles

hGetContents :: MonadIO m => Handle -> m LByteString Source #

Lifted hGetContents

hGet :: MonadIO m => Handle -> Int -> m LByteString Source #

Lifted hGet

hGetNonBlocking :: MonadIO m => Handle -> Int -> m LByteString Source #

Lifted hGetNonBlocking

hPut :: MonadIO m => Handle -> LByteString -> m () Source #

Lifted hPut

hPutNonBlocking :: MonadIO m => Handle -> LByteString -> m LByteString Source #

Lifted hPutNonBlocking

hPutStr :: MonadIO m => Handle -> LByteString -> m () Source #

Lifted hPutStr