My serializer for c++ classes