Hello,

I'm curious is there any way to access extension fields for
FieldOptions(or MessageOptions) in DynamicMessage?

i.e.

We define message and option, like this:

extend google.protobuf.FieldOptions {
    optional string my_opt = 50001;
}

message MyMessage {
    required string my_field [(my_opt) = "opt"];
}

Then we load this .proto in runtime via Importer, get the Message
object from DynamicMessageFactory, then parse encoded message. Now,
using Reflection/Descriptor I want to get all options for
my_field(including extensions), but only standard options are
accessible, all extensions go to UnknownFields, so I can get only
their values but not names. My question: is there any way to get all
options(with extensions) of field/message, if message/option
definitions were loaded in runtime?

-- 
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