inbus
view new-encoding.txt @ 5:8ecb08252c8a
Dictionary unpacker now done.
| author | Eric Hopper <hopper@omnifarious.org> |
|---|---|
| date | Mon Feb 25 20:11:32 2008 -0800 (2008-02-25) |
| parents | |
| children |
line source
1 'c' Count (the type of an enum)
2 A count of something. This is not meant to have the range to
3 represent an arbitrary integer for the purposes of something like
4 cryptography that requires arbitrarily large abstract integers.
6 'm' a multi-precision integer (accepts length modifier giving octets in integer)
7 An arbitrary sized integer.
8 'w' an unsigned multi-precision integer (accepts length modified)
9 An arbitrary sized unsigned integer.
11 'y' a yes/no value, aka a boolean
12 Encoded as a single byte 0 or 1.
14 'b' binary
15 An opaque blob of binary data
17 's' string (accepts a length modifier for fixed length strings)
18 A sequence of UTF-8 encoded characters.
20 'k' integer 8
21 An 8-bit two's complement integer
22 'p' unsigned integer 8
23 An 8-bit integer that is always >= 0 (may also be used for bitfields)
24 'j' integer 16
25 A 16-bit two's complement integer
26 'o' unsigned integer 16 (no, 'o' makes no sense)
27 A 16-bit integer that is always >= 0 (may also be used for bitfields)
28 'i' integer 32
29 A 32-bit two's complement integer
30 'u' integer 32
31 A 32-bit integer that is always >= 0 (may also be used for bitfields)
32 'l' integer 64
33 A 64-bit two's complement integer
34 'n' integer 64
35 A 64-bit integer that is always >= 0 (may also be used for bitfields)
37 'f' floating
38 An IEEE 754 64 bit floating point number.
39 'h' half-size floating
40 An IEEE 754 32 bit floating point number.
41 'g' a giant arbitrary precision floating point (maybe)
42 An IEEE 754 floating point number with a sign + exponent size of 16
43 bits and an arbitrary number of bits of precision.
45 't(...)' Tuple (a ')' terminated list of types)
46 A grouping of values.
47 'a[.]' an array (contains one type, the type of all the elements)
48 Array's, lists and sets are largely indistinguishable in how they
49 look on the wire, and so they are all represented by an
50 array. Array's are not length delimited, there is a flag before
51 each element saying whether or not it's the last one.
52 'd{..}' a dictionary (contains two types, the key type and value type of all the elements)
53 A mapping from keys to values.
54 'v' variant type
55 This is a type where the type is encoded in its value.
