I need to get all fields of Message, which are set, with reflection, so i usegoogle::protobuf::Reflection::ListFields. google::protobuf::Reflection::ListFields returns a vector, that contains google::protobuf::FieldDescriptor(variables of Proto Message) of google::protobuf::Message,
which are currently set.
I have two variables in proto message of type bool, which i set on false and true, so when i call ListFields, it returns a vector without bool, which set on
false, but with bool, which set on true. I suggest it happens because bool in binary format in protobuf messages is Varint type. And when Varint is zero(because 'false' becomes a zero) ListFields thinks that this variable is not set, because it set on zero.
So the question: how can i get this variable if it isn't in Listfields vector?