Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data AsciiString
- length :: AsciiString -> Int
- fromSeptetList :: [Word8] -> AsciiString
- fromByteString :: ByteString -> AsciiString
- fromShortByteString :: ShortByteString -> AsciiString
- toSeptetList :: AsciiString -> [Word8]
- toByteString :: AsciiString -> ByteString
- toShortByteString :: AsciiString -> ShortByteString
Documentation
data AsciiString Source #
Compact representation of ASCII string.
Instances
length :: AsciiString -> Int Source #
Get the amount of septets.
fromSeptetList :: [Word8] -> AsciiString Source #
Construct from a list of septets encoded in Word8
, ignoring the 8th bit.
fromByteString :: ByteString -> AsciiString Source #
Convert from ByteString, ignoring each 8th bit in it.
fromShortByteString :: ShortByteString -> AsciiString Source #
Convert from ShortByteString, ignoring each 8th bit in it.
toSeptetList :: AsciiString -> [Word8] Source #
Convert to a list of septets represented by Word8
with the 8th bit always empty.
toByteString :: AsciiString -> ByteString Source #
Convert to bytestring.
toShortByteString :: AsciiString -> ShortByteString Source #
Convert to short bytestring.