Make serializer a class member