Interface Message

    • Method Detail

      • equals

        boolean equals​(java.lang.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 getDescriptorForType()) and has identical values for all of its fields. Subclasses must implement this; inheriting Object.equals() is incorrect.
        Overrides:
        equals in class java.lang.Object
        Parameters:
        other - object to be compared for equality with this message
        Returns:
        true if the specified object is equal to this message
      • hashCode

        int 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.
        Overrides:
        hashCode in class java.lang.Object
        Returns:
        the hash code value for this message
        See Also:
        Map.hashCode()
      • toBuilder

        Message.Builder toBuilder()
        Description copied from interface: MessageLite
        Constructs a builder initialized with the current message. Use this to derive a new message from the current one.
        Specified by:
        toBuilder in interface MessageLite