added .toBuffer method for easy db serialization
v0.1.3