Adds a serializer/deserializer.
Merge pull request #76 from cauchymop/serializer

Adds a serializer/deserializer.