Data.ASN1.BitArray

asn1-data-0.6.1.2: ASN1 data reader and writer in RAW, BER, DER and CER forms

Safe Haskell | Safe-Inferred

Data.ASN1.BitArray

Synopsis

- data BitArray = BitArray Word64 ByteString
- bitArrayLength :: BitArray -> Word64
- bitArrayGetBit :: BitArray -> Word64 -> Bool
- bitArrayGetData :: BitArray -> ByteString
- toBitArray :: ByteString -> Int -> BitArray

# Documentation

data BitArray

represent a bitarray / bitmap

Constructors

BitArray Word64 ByteString |

Instances

Eq BitArray |
Show BitArray |

bitArrayLength :: BitArray -> Word64

returns the length of bits in this bitarray

bitArrayGetBit :: BitArray -> Word64 -> Bool

get the nth bits

bitArrayGetData :: BitArray -> ByteString

get padded bytestring of the bitarray

toBitArray :: ByteString -> Int -> BitArray

number of bit to skip at the end (padding)