Lazy bitstrings, somewhat similar to lazy bytestrings. This module is intended to be imported qualified.
- data BitString
- empty :: BitString
- bitString :: ByteString -> BitString
- bitStringLazy :: ByteString -> BitString
- unsafeBitString' :: Int64 -> Int64 -> ByteString -> BitString
- take :: Int64 -> BitString -> BitString
- drop :: Int64 -> BitString -> BitString
- splitAt :: Int64 -> BitString -> (BitString, BitString)
- append :: BitString -> BitString -> BitString
- concat :: [BitString] -> BitString
- toList :: BitString -> [Bool]
- fromList :: [Bool] -> BitString
- to01List :: BitString -> [Word8]
- from01List :: [Word8] -> BitString
- null :: BitString -> Bool
- length :: BitString -> Int64
- foldl' :: (a -> Bool -> a) -> a -> BitString -> a
- findSubstring :: BitString -> BitString -> Maybe Int64
- realizeBitStringLazy :: BitString -> ByteString
- realizeBitStringStrict :: BitString -> ByteString
- realizeBitString' :: BitString -> [ByteString]
Documentation
bitString :: ByteString -> BitStringSource
Create a BitString
from a strict ByteString
bitStringLazy :: ByteString -> BitStringSource
Create a BitString
from a lazy ByteString
:: Int64 | offset |
-> Int64 | length |
-> ByteString | source |
-> BitString |
Create a BitString
from a portion of a ByteString
.
Warning! No boundary checks are performed!
from01List :: [Word8] -> BitStringSource