I've generated all my protos with -p:detectMissing flag which works
fine.

However, all the optional strings get generated as
public string mystring {
        get { return _myString ?? ""; }

As a result, empty strings are being transmitted over the wire.  This
requires me to manually edit the getters to "return _myString;".

Is there a way to fix this behavior?

Also, if I have enums with no default 0 enum defined for an optional
enum,  I get an exception "The default enum value ... is not defined
for the optional property..."

Shouldn't the serializer code check to see whether the enum has to be
serialized before throwing this exception?  Setting DefaultValue[null]
doesn't work. The only work around I've found is to add an UNKNOWN
enum = 0 to all enums which is pretty tedious.

Is there a work around for this enum problem?

Thanks

-- 
You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To post to this group, send email to proto...@googlegroups.com.
To unsubscribe from this group, send email to 
protobuf+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/protobuf?hl=en.

Reply via email to