| Copyright | (c) 2010-2013 Vincent Hanquez <vincent@snarc.org> |
|---|---|
| License | BSD-style |
| Stability | experimental |
| Portability | unknown |
| Safe Haskell | Safe-Inferred |
| Language | Haskell2010 |
Data.ASN1.BinaryEncoding.Raw
Description
Raw encoding of binary format (BERDERCER)
Synopsis
- data ASN1Header = ASN1Header !ASN1Class !ASN1Tag !Bool !ASN1Length
- data ASN1Class
- type ASN1Tag = Int
- data ASN1Length
- data ASN1Event
- parseLBS :: ByteString -> Either ASN1Error [ASN1Event]
- parseBS :: ByteString -> Either ASN1Error [ASN1Event]
- toLazyByteString :: [ASN1Event] -> ByteString
- toByteString :: [ASN1Event] -> ByteString
Types
data ASN1Header #
Constructors
| ASN1Header !ASN1Class !ASN1Tag !Bool !ASN1Length |
Instances
| Eq ASN1Header # | |
Defined in Data.ASN1.Types.Lowlevel | |
| Show ASN1Header # | |
Defined in Data.ASN1.Types.Lowlevel Methods showsPrec :: Int -> ASN1Header -> ShowS # show :: ASN1Header -> String # showList :: [ASN1Header] -> ShowS # | |
Constructors
| Universal | |
| Application | |
| Context | |
| Private |
Instances
| Eq ASN1Class # | |
| Ord ASN1Class # | |
| Enum ASN1Class # | |
Defined in Data.ASN1.Types.Lowlevel Methods succ :: ASN1Class -> ASN1Class # pred :: ASN1Class -> ASN1Class # fromEnum :: ASN1Class -> Int # enumFrom :: ASN1Class -> [ASN1Class] # enumFromThen :: ASN1Class -> ASN1Class -> [ASN1Class] # enumFromTo :: ASN1Class -> ASN1Class -> [ASN1Class] # enumFromThenTo :: ASN1Class -> ASN1Class -> ASN1Class -> [ASN1Class] # | |
| Show ASN1Class # | |
data ASN1Length #
Instances
| Eq ASN1Length # | |
Defined in Data.ASN1.Types.Lowlevel | |
| Show ASN1Length # | |
Defined in Data.ASN1.Types.Lowlevel Methods showsPrec :: Int -> ASN1Length -> ShowS # show :: ASN1Length -> String # showList :: [ASN1Length] -> ShowS # | |
Constructors
| Header ASN1Header | |
| Primitive !ByteString | |
| ConstructionBegin | |
| ConstructionEnd |
Parser
parseLBS :: ByteString -> Either ASN1Error [ASN1Event] Source #
Parse one lazy bytestring and returns on success all ASN.1 events associated.
parseBS :: ByteString -> Either ASN1Error [ASN1Event] Source #
Parse one strict bytestring and returns on success all ASN.1 events associated.
Writer
toLazyByteString :: [ASN1Event] -> ByteString Source #
Transform a list of ASN.1 events into a lazy bytestring.
toByteString :: [ASN1Event] -> ByteString Source #
Transform a list of ASN.1 events into a strict bytestring.