protocol buffer使用中的问题This is supposed to be overridden by subclasses

Exception in thread "main" java.lang.UnsupportedOperationException: This is supposed to be overridden by subclasses.

at com.google.protobuf.GeneratedMessage.getUnknownFields(GeneratedMessage.java:180)

at com.test.utill.TextFormat$Printer.print(TextFormat.java:251)

at com.test.utill.MessageLiteToStringUtil.toString(MessageLiteToStringUtil.java:20)

at com.test.protocol.ProtocolTest.main(ProtocolTest.java:23)

出现这个问题是由于protoc.exe的版本和jar包版本不匹配


你可能感兴趣的:(protoc)