@Override
    public Object extractAndConvert(FieldDescriptor field, Message msg) {
      int count = msg.getRepeatedFieldCount(field);
      if (count == 0) {
        return null;
      }
      Object[] val = new Object[count];
      for (int j = 0; j < count; ++j) {
        val[j] = convertor.convert(msg.getRepeatedField(field, j));
      }
      return val;
    }
Convert the given writable to a message.
@param writable The writable object containing the message.
@return The converted message object.
@throws SerDeException
ql/src/java/org/apache/hadoop/hive/ql/io/protobuf/ProtobufSerDe.java