Portability | portable |
---|---|
Stability | unstable |
Maintainer | claudiusmaximus@goto10.org |
Safe Haskell | Safe-Infered |
Copy bit array data to and from ByteStrings.
- toByteString :: Ix i => BitArray i -> ByteString
- fromByteString :: Ix i => (i, i) -> ByteString -> BitArray i
- toByteStringIO :: Ix i => IOBitArray i -> IO ByteString
- fromByteStringIO :: Ix i => (i, i) -> ByteString -> IO (IOBitArray i)
Immutable copying.
toByteString :: Ix i => BitArray i -> ByteStringSource
Copy to a ByteString. The most significant bits of the last byte are padded with 0 unless the array was a multiple of 8 bits in size.
:: Ix i | |
=> (i, i) | bounds |
-> ByteString | packed elems |
-> BitArray i |
Copy from a ByteString. Much like listArray
but with packed bits.
Mutable copying.
toByteStringIO :: Ix i => IOBitArray i -> IO ByteStringSource
Copy to a ByteString. The most significant bits of the last byte are padded with 0 unless the array was a multiple of 8 bits in size.
:: Ix i | |
=> (i, i) | bounds |
-> ByteString | packed elems |
-> IO (IOBitArray i) |
Copy from a ByteString. Much like newListArray
but with packed bits.