Annotation Type ProtoField
Binds a ProtoMessage field to a protobuf field tag. Tags must
be positive, unique within the message, and correspond to the
tag declared in the upstream .proto file.
Optional wireType() forces a non-default scalar encoding for
integer fields. Defaults to ProtoField.WireKind.DEFAULT, which selects
varint for int32 / int64 / bool, fixed32 / fixed64 for
float / double, and length-delimited for strings, byte arrays,
nested messages, and repeated packed scalars. Specify
ProtoField.WireKind.SINT for ZigZag-encoded signed integers, or
ProtoField.WireKind.FIXED for fixed-width unsigned integers (matches
fixed32 / fixed64 in proto3).
-
Nested Class Summary
Nested Classes -
Required Element Summary
Required ElementsModifier and TypeRequired ElementDescriptionintProtobuf field tag (positive integer, unique per message). -
Optional Element Summary
Optional ElementsModifier and TypeOptional ElementDescriptionOptional override of the Java field name when the generator had to rename it to a valid identifier.Non-default integer encoding selector.
-
Element Details
-
tag
int tagProtobuf field tag (positive integer, unique per message). -
name
String nameOptional override of the Java field name when the generator had to rename it to a valid identifier. Carries the original.protoname so introspection tooling can recover it.- Default:
""
-
wireType
ProtoField.WireKind wireTypeNon-default integer encoding selector. Has no effect for non-integer fields.- Default:
DEFAULT
-