Copyright © 2013, Andreas Stenius
Authors: Andreas Stenius (kaos@astekk.se).
Cap'n Proto value support.
Everything value.value_type() = ecapnp:value_type()
get/2 | Decode data from Cap'n Proto format. |
get/3 | Decode data from Cap'n Proto format. |
set/2 | Encode value to Cap'n Proto format. |
set/3 | Encode value to Cap'n Proto format. |
size/1 | Get number of bits for ValueType . |
get(ValueType::value_type(), Data::binary()) -> number() | boolean()
Decode data from Cap'n Proto format.
get(ValueType::value_type(), Data::binary(), Default::binary()) -> number() | boolean()
Decode data from Cap'n Proto format.
TheData
is XOR'ed with Default
prior to decoding.
set(ValueType::value_type(), Value::number() | boolean()) -> binary()
Encode value to Cap'n Proto format.
set(ValueType::value_type(), Value::number() | boolean(), Default::binary()) -> binary()
Encode value to Cap'n Proto format.
The result is XOR'ed withDefault
.
size(ValueType::value_type()) -> non_neg_integer()
Get number of bits for ValueType
.
Generated by EDoc, May 30 2014, 12:56:29.