There is no way to remove the underscores without changing protoc. But why
do you want to get rid of the underscores anyway? Those variables are just
a private implementation detail and make no difference to the public API.

On Wed, Sep 5, 2018 at 1:07 PM Chris Zhang <[email protected]> wrote:

> Hi,
>
> I am new to Protobuf, and recently I found out that the java generated
> code by protobuf has underscore by the end of each field names.
>
> For example,
>
> protobuf message file look like this:
>
> message DummyMessage [
>
>     string some_id = 1;
>     bool is_active = 2;
> }
>
> The generated java code is like this:
>
> Class DummyMessage {
>
>     String someId_;
>     boolean isActive_;
>
> }
>
> Is there any way to get rid of the underscore of each field?
>
> Thanks,
>
>
> --
> 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 post to this group, send email to [email protected].
> Visit this group at https://groups.google.com/group/protobuf.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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 post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/protobuf.
For more options, visit https://groups.google.com/d/optout.

Reply via email to