serialization of current instance