code: def _serialize_value_for_xml(self, value):
      
      if value is not None:
        value_serialized = self.serializer.serialize(value)
      else:
        value_serialized = ''
      return value_serialized
docs: See base class.