making abstract data serializable