On Jun 24, 2013, at 2:15 PM, Bjorn Reese
On 06/24/2013 01:34 PM, Dominik Charousset wrote:
Actually, it is just a simple 6-bit encoding using a lookup table [1]. In this way, the mapping is guaranteed to be collision free and invertible.
Base-64 is also just a simple 6-bit encoding using a lookup table ;-)
Looking at the code you referenced, it appears that your encoding algorithm is the same as the base-64 algorithm, but your lookup table is slightly different (yours includes space and underscore instead of plus and slash, and the rest are offset by one.)
Thanks for the answer.
Ok, let's agree that it's a Base64-ish algorithm. ;) However, the atom mapping does not use padding. Instead, it uses the remaining 4 bits of the 64bit integer to indicate the start of the string (leading zeros are ignored until '1111' is reached) [1]. [1] https://github.com/Neverlord/libcppa/blob/master/src/atom.cpp