Livecode Array Encoding / Decoding using other platforms?

ambassador at fourthworld.com ambassador at fourthworld.com
Tue May 21 03:33:09 EDT 2019


Tom Glod wrote:

> Thanks for that tip of undertanding about the array encoding.  Explains
> why its really fast.
> 
> Its not really the encoding / decoding speed i am thinking about.  Lets
> see if I can explain better.
> 
> I can try to read C code in the codebase to see if i can see how the
> data gets processed....maybe i will peek out of interest .......if i 
> can
> even find the arrayencode function in the c codebase....
> 
> Its probably easier to encode into Json and baseencode any binary
> data......and just deal with text chunks instead of blobs.

What will you be doing with the data?

If both producer and consumer of the data are written in LiveCode, it's 
really hard to beat LSON (my pet name for encoded arrays).  LSON is to 
LiveCode what JSON is to JavaScript, as BSON is to MongoDB. It is the 
most efficient, most with-the-grain serialization in this language.

Of course, if you need to talk to things not written in LC, you'll have 
to write a parser in that language.  My notes could help, but there 
would be no benefit.  For interoperability, use JSON or XML.

But if both client and server are LC, just enjoy LSON without even 
having to worry how it's made. Efficient, robust, easy to use - what's 
not to love?

- rg/4w















More information about the use-livecode mailing list