cbor library

Classes

CborBase64
A CBOR string containing a base 64 value.
CborBase64Url
A CBOR string containing a base 64 url safe value.
CborBigFloat
A CBOR fraction (m * (2 ** e)).
CborBigInt
A CBOR big int.
CborBool
A CBOR boolean value.
CborBytes
A CBOR byte array.
CborCodec
A CBOR encoder and decoder.
CborDateTime
A CBOR datetime.
CborDateTimeFloat
A CBOR date time encoded as seconds since epoch in a float.
CborDateTimeInt
A CBOR datetieme encoded as seconds since epoch.
CborDateTimeString
A CBOR string which encodes a datetime.
CborDecimalFraction
A CBOR fraction (m * (10 ** e)).
CborDecoder
A CBOR decoder.
CborEncodeDefiniteLengthBytes
Use this to force the CborEncoder to encode an definite length byte string.
CborEncodeDefiniteLengthList
Use this to force the CborEncoder to encode an definite length list.
CborEncodeDefiniteLengthMap
Use this to force the CborEncoder to encode an definite length dictionary.
CborEncodeDefiniteLengthString
Use this to force the CborEncoder to encode an definite length string.
CborEncodeIndefiniteLengthBytes
Use this to force the CborEncoder to encode an indefinite length byte string.
CborEncodeIndefiniteLengthList
Use this to force the CborEncoder to encode an indefinite length list.
CborEncodeIndefiniteLengthMap
Use this to force the CborEncoder to encode an indefinite length dictionary.
CborEncodeIndefiniteLengthString
Use this to force the CborEncoder to encode an indefinite length string.
CborEncoder
A CBOR encoder.
CborFloat
A CBOR float.
CborInt
A CBOR integer or big number.
CborJsonEncoder
Encodes CBOR into JSON.
CborList
A CBOR array.
CborMap
A CBOR map.
CborMime
A CBOR string containing a regular expression.
CborNull
A CBOR null value.
CborRegex
A CBOR string containing a regular expression.
CborSimpleCodec
A simple codec for CBOR, using CborSimpleEncoder and CborSimpleDecoder.
CborSimpleDecoder
A simple decoder for CBOR.
CborSimpleEncoder
A simple encoder for CBOR.
CborSimpleValue
A CBOR simple value without any additional content.
CborSmallInt
A CBOR integer which can be represented losslessly as int.
CborString
A CBOR string encoded in UTF-8.
CborTag
Hint for the content of something.
CborUndefined
A CBOR undefined value.
CborUri
A CBOR string containing URI.
CborValue
A CBOR value.

Enums

CborFloatPrecision
Enumeration to allow the user to select which level of precision to use encoding a CBOR float. Defaults to 'automatic'
CborLengthType

Constants

cbor → const CborCodec
A constant instance of a CBOR codec, using default parameters.
kCborDefiniteLengthThreshold → const int

Functions

cborDecode(List<int> value) CborValue
Alias for cbor.decode.
cborEncode(CborValue value) List<int>
Alias for cbor.encode.
cborPrettyPrint(List<int> input, {int indent = 2}) String
Pretty print a CBOR input.

Exceptions / Errors

CborCyclicError
Raised when object could not be codified due to cyclic references.
CborMalformedException
An exception raised when decoding.