Lib: Serialize

This project is abandoned.

Whether this project is out of date or its author marked it as abandoned, this project is no longer maintained.

If you wish to take this project over, please report it and state your intentions.

I needed to store and export realy big (+-500 mb) chunks of data from wow, therefore I created this library... It serializes wow lua structures, uses references so it can handle almost any lua table (even with cyclic table references for example). Because of using references, it actually stores data really effectively (it is a type of simple compression) so it can help to store persistent addon data in much smaller 'saved variables' files. It was also optimalized for speed (but sure more can be done there). Since I needed to use those data in web environment I ported deserialization to javascript...

but still it is beta and I am testing different approaches (for example base100 coding for float number storage)...

How to use:

local Serializer=LibStub("LibSerialize");  -- get it

String = Serializer:Serialize(Data); -- serialize those Data into a String

Data = Serializer:DeSerialize(String); -- deserialize that String back into Data

todo: many many things...these pop up in my mind

a) preinitialization with well known strings (for addons to reduce actual amount of data transferred)

b) number-convert cache for speed up

c) some LRU type cache especialy for floating number serialization

You must login to post a comment. Don't have an account? Register to get one!

  • 1 comment
  • Avatar of DieenDieen DieenDieen Jan 10, 2012 at 13:47 UTC - 0 likes

    just to comment why base100 seems ok (and not something bigger..)..the encoded string is still utf8 compatible...

  • 1 comment


Date created
Jan 10, 2012
Last update
Jan 29, 2012
Development stage
  • enUS
Public Domain
Recent files