com.google.protobuf.SingleFieldBuilderV3< MType extends AbstractMessage, BType extends AbstractMessage.Builder, IType extends MessageOrBuilder > Class Template Reference

Detailed Description

implements a structure that a protocol message uses to hold a single field of another protocol message. It supports the classical use case of setting an immutable Message as the value of the field and is highly optimized around this.

It also supports the additional use case of setting a Message.Builder as the field and deferring conversion of that

to an immutable

. In this way, it's possible to maintain a tree of

's that acts as a fully read/write data structure.
Logically, one can think of a tree of builders as converting the entire tree to messages when build is called on the root or when any method is called that desires a Message instead of a Builder. In terms of the implementation, the

and

RepeatedFieldBuilderV3

classes cache messages that were created so that messages only need to be created when some change occurred in its builder or a builder for one of its descendants.

Parameters
<MType>the type of message for the field
<BType>the type of builder for the field
<IType>the common interface for the message and the builder
Author
jonp@.nosp@m.goog.nosp@m.le.co.nosp@m.m (Jon Perlow)

Definition at line 55 of file bloaty/third_party/protobuf/java/core/src/main/java/com/google/protobuf/SingleFieldBuilderV3.java.


The documentation for this class was generated from the following file:
Builder
Definition: bloaty/third_party/protobuf/ruby/ext/google/protobuf_c/protobuf.h:170
com.google.protobuf.SingleFieldBuilderV3.SingleFieldBuilderV3
SingleFieldBuilderV3(MType message, AbstractMessage.BuilderParent parent, boolean isClean)
Definition: bloaty/third_party/protobuf/java/core/src/main/java/com/google/protobuf/SingleFieldBuilderV3.java:79
Message
Definition: protobuf/php/ext/google/protobuf/message.c:53


grpc
Author(s):
autogenerated on Fri May 16 2025 03:03:07