Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- der :: AsnEncoding a -> a -> ByteString
- toDefinitionString :: AsnEncoding a -> String
- sequence :: [Field a] -> AsnEncoding a
- sequenceOf :: Foldable f => AsnEncoding a -> AsnEncoding (f a)
- choice :: [a] -> (a -> ValueAndEncoding) -> AsnEncoding a
- tag :: TagClass -> Int -> Explicitness -> AsnEncoding a -> AsnEncoding a
- implicitTag :: Tag -> AsnEncoding a -> AsnEncoding a
- required :: FieldName -> (a -> b) -> AsnEncoding b -> Field a
- optional :: FieldName -> (a -> Maybe b) -> AsnEncoding b -> Field a
- defaulted :: (Eq b, Show b) => FieldName -> (a -> b) -> AsnEncoding b -> b -> Field a
- option :: Int -> OptionName -> b -> AsnEncoding b -> ValueAndEncoding
- integer :: AsnEncoding Integer
- integerRanged :: Integer -> Integer -> AsnEncoding Integer
- int32 :: AsnEncoding Int32
- int :: AsnEncoding Int
- word32 :: AsnEncoding Word32
- word64 :: AsnEncoding Word64
- word :: AsnEncoding Word
- octetString :: AsnEncoding ByteString
- octetStringWord8 :: AsnEncoding Word8
- octetStringWord32 :: AsnEncoding Word32
- utf8String :: AsnEncoding Text
- null :: AsnEncoding ()
- null' :: AsnEncoding a
- objectIdentifier :: AsnEncoding ObjectIdentifier
- int64Log256 :: Int64 -> Int
- encodeLength :: Int64 -> ByteString
Run Encoding
der :: AsnEncoding a -> a -> ByteString Source #
toDefinitionString :: AsnEncoding a -> String Source #
Build Encoding
Constructed
sequence :: [Field a] -> AsnEncoding a Source #
sequenceOf :: Foldable f => AsnEncoding a -> AsnEncoding (f a) Source #
choice :: [a] -> (a -> ValueAndEncoding) -> AsnEncoding a Source #
tag :: TagClass -> Int -> Explicitness -> AsnEncoding a -> AsnEncoding a Source #
implicitTag :: Tag -> AsnEncoding a -> AsnEncoding a Source #
Fields
option :: Int -> OptionName -> b -> AsnEncoding b -> ValueAndEncoding Source #
Primitive
integerRanged :: Integer -> Integer -> AsnEncoding Integer Source #
int32 :: AsnEncoding Int32 Source #
int :: AsnEncoding Int Source #
word :: AsnEncoding Word Source #
null :: AsnEncoding () Source #
null' :: AsnEncoding a Source #
Anything can be encoded as NULL
by simply discarding it. Typically,
encoding a type with more than one inhabitant as NULL
is a mistake,
so the more restrictive null
is to be preferred.
int64Log256 :: Int64 -> Int Source #
encodeLength :: Int64 -> ByteString Source #