public abstract class GeneratedMessageV3 extends AbstractMessage implements SerializableAll generated protocol message classes extend this class. This class implements most of the Message and Builder interfaces using Java reflection. Users can ignore this class and pretend that generated messages implement the Message interface directly.
Inheritance
Object > AbstractMessageLite<MessageType,BuilderType> > AbstractMessage > GeneratedMessageV3Implements
SerializableStatic Fields
alwaysUseFieldBuilders
protected static boolean alwaysUseFieldBuildersFor testing. Allows a test to disable the optimization that avoids using field builders for nested messages until they are requested. By disabling this optimization, existing tests can be reused to test the field builders.
| Field Value | |
|---|---|
| Type | Description |
boolean |
|
Static Methods
<M>parseDelimitedWithIOException(Parser<M> parser, InputStream input)
protected static M <M>parseDelimitedWithIOException(Parser<M> parser, InputStream input)| Parameters | |
|---|---|
| Name | Description |
parser |
Parser<M> |
input |
InputStream |
| Returns | |
|---|---|
| Type | Description |
M |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
<M>parseDelimitedWithIOException(Parser<M> parser, InputStream input, ExtensionRegistryLite extensions)
protected static M <M>parseDelimitedWithIOException(Parser<M> parser, InputStream input, ExtensionRegistryLite extensions)| Parameters | |
|---|---|
| Name | Description |
parser |
Parser<M> |
input |
InputStream |
extensions |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
M |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
<M>parseWithIOException(Parser<M> parser, CodedInputStream input)
protected static M <M>parseWithIOException(Parser<M> parser, CodedInputStream input)| Parameters | |
|---|---|
| Name | Description |
parser |
Parser<M> |
input |
CodedInputStream |
| Returns | |
|---|---|
| Type | Description |
M |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
<M>parseWithIOException(Parser<M> parser, CodedInputStream input, ExtensionRegistryLite extensions)
protected static M <M>parseWithIOException(Parser<M> parser, CodedInputStream input, ExtensionRegistryLite extensions)| Parameters | |
|---|---|
| Name | Description |
parser |
Parser<M> |
input |
CodedInputStream |
extensions |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
M |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
<M>parseWithIOException(Parser<M> parser, InputStream input)
protected static M <M>parseWithIOException(Parser<M> parser, InputStream input)| Parameters | |
|---|---|
| Name | Description |
parser |
Parser<M> |
input |
InputStream |
| Returns | |
|---|---|
| Type | Description |
M |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
<M>parseWithIOException(Parser<M> parser, InputStream input, ExtensionRegistryLite extensions)
protected static M <M>parseWithIOException(Parser<M> parser, InputStream input, ExtensionRegistryLite extensions)| Parameters | |
|---|---|
| Name | Description |
parser |
Parser<M> |
input |
InputStream |
extensions |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
M |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
<V>serializeBooleanMapTo(CodedOutputStream out, MapField<Boolean,V> field, MapEntry<Boolean,V> defaultEntry, int fieldNumber)
protected static void <V>serializeBooleanMapTo(CodedOutputStream out, MapField<Boolean,V> field, MapEntry<Boolean,V> defaultEntry, int fieldNumber)| Parameters | |
|---|---|
| Name | Description |
out |
CodedOutputStream |
field |
MapField<Boolean,V> |
defaultEntry |
MapEntry<Boolean,V> |
fieldNumber |
int |
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
<V>serializeIntegerMapTo(CodedOutputStream out, MapField<Integer,V> field, MapEntry<Integer,V> defaultEntry, int fieldNumber)
protected static void <V>serializeIntegerMapTo(CodedOutputStream out, MapField<Integer,V> field, MapEntry<Integer,V> defaultEntry, int fieldNumber)| Parameters | |
|---|---|
| Name | Description |
out |
CodedOutputStream |
field |
MapField<Integer,V> |
defaultEntry |
MapEntry<Integer,V> |
fieldNumber |
int |
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
<V>serializeLongMapTo(CodedOutputStream out, MapField<Long,V> field, MapEntry<Long,V> defaultEntry, int fieldNumber)
protected static void <V>serializeLongMapTo(CodedOutputStream out, MapField<Long,V> field, MapEntry<Long,V> defaultEntry, int fieldNumber)| Parameters | |
|---|---|
| Name | Description |
out |
CodedOutputStream |
field |
MapField<Long,V> |
defaultEntry |
MapEntry<Long,V> |
fieldNumber |
int |
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
<V>serializeStringMapTo(CodedOutputStream out, MapField<String,V> field, MapEntry<String,V> defaultEntry, int fieldNumber)
protected static void <V>serializeStringMapTo(CodedOutputStream out, MapField<String,V> field, MapEntry<String,V> defaultEntry, int fieldNumber)| Parameters | |
|---|---|
| Name | Description |
out |
CodedOutputStream |
field |
MapField<String,V> |
defaultEntry |
MapEntry<String,V> |
fieldNumber |
int |
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
canUseUnsafe()
protected static boolean canUseUnsafe()| Returns | |
|---|---|
| Type | Description |
boolean |
|
computeStringSize(int fieldNumber, Object value)
protected static int computeStringSize(int fieldNumber, Object value)| Parameters | |
|---|---|
| Name | Description |
fieldNumber |
int |
value |
Object |
| Returns | |
|---|---|
| Type | Description |
int |
|
computeStringSizeNoTag(Object value)
protected static int computeStringSizeNoTag(Object value)| Parameter | |
|---|---|
| Name | Description |
value |
Object |
| Returns | |
|---|---|
| Type | Description |
int |
|
emptyBooleanList()
protected static Internal.BooleanList emptyBooleanList()| Returns | |
|---|---|
| Type | Description |
Internal.BooleanList |
|
emptyDoubleList()
protected static Internal.DoubleList emptyDoubleList()| Returns | |
|---|---|
| Type | Description |
Internal.DoubleList |
|
emptyFloatList()
protected static Internal.FloatList emptyFloatList()| Returns | |
|---|---|
| Type | Description |
Internal.FloatList |
|
emptyIntList()
protected static Internal.IntList emptyIntList()| Returns | |
|---|---|
| Type | Description |
Internal.IntList |
|
emptyLongList()
protected static Internal.LongList emptyLongList()| Returns | |
|---|---|
| Type | Description |
Internal.LongList |
|
isStringEmpty(Object value)
protected static boolean isStringEmpty(Object value)| Parameter | |
|---|---|
| Name | Description |
value |
Object |
| Returns | |
|---|---|
| Type | Description |
boolean |
|
mutableCopy(Internal.BooleanList list)
protected static Internal.BooleanList mutableCopy(Internal.BooleanList list)| Parameter | |
|---|---|
| Name | Description |
list |
Internal.BooleanList |
| Returns | |
|---|---|
| Type | Description |
Internal.BooleanList |
|
mutableCopy(Internal.DoubleList list)
protected static Internal.DoubleList mutableCopy(Internal.DoubleList list)| Parameter | |
|---|---|
| Name | Description |
list |
Internal.DoubleList |
| Returns | |
|---|---|
| Type | Description |
Internal.DoubleList |
|
mutableCopy(Internal.FloatList list)
protected static Internal.FloatList mutableCopy(Internal.FloatList list)| Parameter | |
|---|---|
| Name | Description |
list |
|