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. [image: Снимок экрана от 2022-08-02 18-13-22.png]
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?

-- 
You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/protobuf/270b38e3-57a4-499d-8c92-3beec2a19f92n%40googlegroups.com.

Reply via email to