#include </data/code/userver/libraries/protobuf/include/userver/protobuf/json/convert_options.hpp>
Options which affect how protobuf message is converted to a JSON ValueBuilder/Value.
Definition at line 19 of file convert_options.hpp.
Public Attributes | |
| bool | always_print_fields_with_no_presence = false |
| Always output protobuf message fields that do not have explicit presence. This fields are: | |
| bool | always_print_enums_as_ints = false |
| Output enum values as integers, not as their string names. | |
| bool | preserve_proto_field_names = false |
Output field names exactly how specified in the proto file (usually lower_snake_case). By default, protobuf message field names are converted to lowerCamelCase format. | |
| bool protobuf::json::PrintOptions::always_print_enums_as_ints = false |
Output enum values as integers, not as their string names.
Definition at line 27 of file convert_options.hpp.
| bool protobuf::json::PrintOptions::always_print_fields_with_no_presence = false |
Always output protobuf message fields that do not have explicit presence. This fields are:
Definition at line 24 of file convert_options.hpp.
| bool protobuf::json::PrintOptions::preserve_proto_field_names = false |
Output field names exactly how specified in the proto file (usually lower_snake_case). By default, protobuf message field names are converted to lowerCamelCase format.
json_name option attached, then it's value is used for the JSON key name and this option does not have effect. google.protobuf.FieldMask paths during conversion. I.e., field names inside FieldMask are always encoded in lowerCamelCase no matter whether preserve_proto_field_names is on or off. Moreover, json_name option is also not taken into account for FieldMask paths. Definition at line 37 of file convert_options.hpp.