Classes | Public Member Functions | List of all members
com.google.protobuf.Message Interface Reference
Inheritance diagram for com.google.protobuf.Message:
Inheritance graph
[legend]

Classes

interface  Builder
 

Public Member Functions

boolean equals (Object other)
 
boolean equals (Object other)
 
Parser<? extends MessagegetParserForType ()
 
Parser<? extends MessagegetParserForType ()
 
int hashCode ()
 
int hashCode ()
 
Builder newBuilderForType ()
 
Builder newBuilderForType ()
 
Builder toBuilder ()
 
Builder toBuilder ()
 
String toString ()
 
String toString ()
 
- Public Member Functions inherited from com.google.protobuf.MessageLite
int getSerializedSize ()
 
int getSerializedSize ()
 
byte[] toByteArray ()
 
byte[] toByteArray ()
 
ByteString toByteString ()
 
ByteString toByteString ()
 
void writeDelimitedTo (OutputStream output) throws IOException
 
void writeDelimitedTo (OutputStream output) throws IOException
 
void writeTo (CodedOutputStream output) throws IOException
 
void writeTo (CodedOutputStream output) throws IOException
 
void writeTo (OutputStream output) throws IOException
 
void writeTo (OutputStream output) throws IOException
 
- Public Member Functions inherited from com.google.protobuf.MessageLiteOrBuilder
boolean isInitialized ()
 
boolean isInitialized ()
 
- Public Member Functions inherited from com.google.protobuf.MessageOrBuilder
List< String > findInitializationErrors ()
 
List< String > findInitializationErrors ()
 
Map< Descriptors.FieldDescriptor, Object > getAllFields ()
 
Map< Descriptors.FieldDescriptor, Object > getAllFields ()
 
Message getDefaultInstanceForType ()
 
Message getDefaultInstanceForType ()
 
Descriptors.Descriptor getDescriptorForType ()
 
Descriptors.Descriptor getDescriptorForType ()
 
Object getField (Descriptors.FieldDescriptor field)
 
Object getField (Descriptors.FieldDescriptor field)
 
String getInitializationErrorString ()
 
String getInitializationErrorString ()
 
Descriptors.FieldDescriptor getOneofFieldDescriptor (Descriptors.OneofDescriptor oneof)
 
Descriptors.FieldDescriptor getOneofFieldDescriptor (Descriptors.OneofDescriptor oneof)
 
Object getRepeatedField (Descriptors.FieldDescriptor field, int index)
 
Object getRepeatedField (Descriptors.FieldDescriptor field, int index)
 
int getRepeatedFieldCount (Descriptors.FieldDescriptor field)
 
int getRepeatedFieldCount (Descriptors.FieldDescriptor field)
 
UnknownFieldSet getUnknownFields ()
 
UnknownFieldSet getUnknownFields ()
 
boolean hasField (Descriptors.FieldDescriptor field)
 
boolean hasField (Descriptors.FieldDescriptor field)
 
boolean hasOneof (Descriptors.OneofDescriptor oneof)
 
boolean hasOneof (Descriptors.OneofDescriptor oneof)
 

Detailed Description

Abstract interface implemented by Protocol Message objects.

See also MessageLite, which defines most of the methods that typical users care about. Message adds to it methods that are not available in the "lite" runtime. The biggest added features are introspection and reflection – i.e., getting descriptors for the message type and accessing the field values dynamically.

Author
kento.nosp@m.n@go.nosp@m.ogle..nosp@m.com Kenton Varda

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

Member Function Documentation

◆ equals() [1/2]

boolean com.google.protobuf.Message.equals ( Object  other)

Compares the specified object with this message for equality. Returns

true

if the given object is a message of the same type (as defined by

) and has identical values for all of its fields. Subclasses must implement this; inheriting

Object.equals()

is incorrect.

Parameters
otherobject to be compared for equality with this message
Returns
true
if the specified object is equal to this message

Implemented in com.google.protobuf.AbstractMessage, and com.google.protobuf.AbstractMessage.

◆ equals() [2/2]

boolean com.google.protobuf.Message.equals ( Object  other)

Compares the specified object with this message for equality. Returns

true

if the given object is a message of the same type (as defined by

) and has identical values for all of its fields. Subclasses must implement this; inheriting

Object.equals()

is incorrect.

Parameters
otherobject to be compared for equality with this message
Returns
true
if the specified object is equal to this message

Implemented in com.google.protobuf.AbstractMessage, and com.google.protobuf.AbstractMessage.

◆ getParserForType() [1/2]

Parser<? extends Message> com.google.protobuf.Message.getParserForType ( )

◆ getParserForType() [2/2]

Parser<? extends Message> com.google.protobuf.Message.getParserForType ( )

◆ hashCode() [1/2]

int com.google.protobuf.Message.hashCode ( )

Returns the hash code value for this message. The hash code of a message should mix the message's type (object identity of the descriptor) with its contents (known and unknown field values). Subclasses must implement this; inheriting

Object.hashCode()

is incorrect.

Returns
the hash code value for this message
See also
Map::hashCode()

Implemented in com.google.protobuf.AbstractMessage, and com.google.protobuf.AbstractMessage.

◆ hashCode() [2/2]

int com.google.protobuf.Message.hashCode ( )

Returns the hash code value for this message. The hash code of a message should mix the message's type (object identity of the descriptor) with its contents (known and unknown field values). Subclasses must implement this; inheriting

Object.hashCode()

is incorrect.

Returns
the hash code value for this message
See also
Map::hashCode()

Implemented in com.google.protobuf.AbstractMessage, and com.google.protobuf.AbstractMessage.

◆ newBuilderForType() [1/2]

Builder com.google.protobuf.Message.newBuilderForType ( )

◆ newBuilderForType() [2/2]

Builder com.google.protobuf.Message.newBuilderForType ( )

◆ toBuilder() [1/2]

Builder com.google.protobuf.Message.toBuilder ( )

◆ toBuilder() [2/2]

Builder com.google.protobuf.Message.toBuilder ( )

◆ toString() [1/2]

String com.google.protobuf.Message.toString ( )

Converts the message to a string in protocol buffer text format. This is just a trivial wrapper around TextFormat.Printer#printToString(MessageOrBuilder).

Implemented in com.google.protobuf.AbstractMessage, and com.google.protobuf.AbstractMessage.

◆ toString() [2/2]

String com.google.protobuf.Message.toString ( )

Converts the message to a string in protocol buffer text format. This is just a trivial wrapper around TextFormat.Printer#printToString(MessageOrBuilder).

Implemented in com.google.protobuf.AbstractMessage, and com.google.protobuf.AbstractMessage.


The documentation for this interface was generated from the following file:
com.google.protobuf.MessageOrBuilder.getDescriptorForType
Descriptors.Descriptor getDescriptorForType()


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