public int getSerializedSize() { int size = memoizedSerializedSize; if (size != -1) return size; size = 0; if (((bitField0_ & 0x00000001) == 0x00000001)) { size += org.apache.pulsar.shaded.com.google.protobuf.v241.CodedOutputStream .computeBytesSize(1, getKeyBytes()); } if (((bitField0_ & 0x00000002) == 0x00000002)) { size += org.apache.pulsar.shaded.com.google.protobuf.v241.CodedOutputStream .computeBytesSize(2, value_); } for (int i = 0; i < metadata_.size(); i++) { size += org.apache.pulsar.shaded.com.google.protobuf.v241.CodedOutputStream .computeMessageSize(3, metadata_.get(i)); } memoizedSerializedSize = size; return size; }
public void writeTo(org.apache.pulsar.common.util.protobuf.ByteBufCodedOutputStream output) throws java.io.IOException { getSerializedSize(); if (((bitField0_ & 0x00000001) == 0x00000001)) { output.writeBytes(1, getKeyBytes()); } if (((bitField0_ & 0x00000002) == 0x00000002)) { output.writeBytes(2, value_); } for (int i = 0; i < metadata_.size(); i++) { output.writeMessage(3, metadata_.get(i)); } }
public void writeTo(org.apache.pulsar.common.util.protobuf.ByteBufCodedOutputStream output) throws java.io.IOException { getSerializedSize(); if (((bitField0_ & 0x00000001) == 0x00000001)) { output.writeBytes(1, getKeyBytes()); } if (((bitField0_ & 0x00000002) == 0x00000002)) { output.writeBytes(2, value_); } for (int i = 0; i < metadata_.size(); i++) { output.writeMessage(3, metadata_.get(i)); } }
public int getSerializedSize() { int size = memoizedSerializedSize; if (size != -1) return size; size = 0; if (((bitField0_ & 0x00000001) == 0x00000001)) { size += org.apache.pulsar.shaded.com.google.protobuf.v241.CodedOutputStream .computeBytesSize(1, getKeyBytes()); } if (((bitField0_ & 0x00000002) == 0x00000002)) { size += org.apache.pulsar.shaded.com.google.protobuf.v241.CodedOutputStream .computeBytesSize(2, value_); } for (int i = 0; i < metadata_.size(); i++) { size += org.apache.pulsar.shaded.com.google.protobuf.v241.CodedOutputStream .computeMessageSize(3, metadata_.get(i)); } memoizedSerializedSize = size; return size; }