hoangduit / protobuf-net

Automatically exported from code.google.com/p/protobuf-net
Other
0 stars 0 forks source link

Ability to enable EnumPassthru for all enums by default #405

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
This is a feature request to be able to enable EnumPassthru for all serialized 
enum types.

- My DTOs do not have any knowledge of protobuf (so using 
ProtoContractAttribute is out).

- Tagging every enum with the FlagsAttribute (or another attribute derived from 
it to make it less ugly) is dirty and prone to error if forgotten.

- Use of RuntimeTypeModel would require reflecting and iterating through all 
enums in the application, and registering many types that will never be 
serialized.

Is there another approach I have missed?

Original issue reported on code.google.com by r...@rastedt.com on 9 Sep 2013 at 1:33

GoogleCodeExporter commented 9 years ago
This is a feature that I'm also interested in.

Original comment by voidedweasel@gmail.com on 8 Oct 2013 at 12:32