def write_to_string
      string_io = StringIO.new.set_encoding(Encoding::BINARY)
      write_to_string_io(string_io)
      string_io.string
    end
def write_to_string
      string_io = StringIO.new.set_encoding(Encoding::BINARY)
      write_to_string_io(string_io)
      string_io.string
    end
Serialize the message to a String.

 @return [String] the serialized message, in a String