Record Class WrappedMessage.Tag<T>
java.lang.Object
java.lang.Record
org.infinispan.protostream.WrappedMessage.Tag<T>
- All Implemented Interfaces:
WrappedMessage.ValueOrTag<T>
- Enclosing class:
WrappedMessage
private static record WrappedMessage.Tag<T>(int tag)
extends Record
implements WrappedMessage.ValueOrTag<T>
- Since:
- 1.0
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.intgetTag()final inthashCode()Returns a hash code value for this object.booleanhasTag()inttag()Returns the value of thetagrecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from interface WrappedMessage.ValueOrTag
getValue, hasValue
-
Field Details
-
tag
private final int tagThe field for thetagrecord component.
-
-
Constructor Details
-
Tag
private Tag(int tag) Creates an instance of aTagrecord class.- Parameters:
tag- the value for thetagrecord component
-
-
Method Details
-
hasTag
public boolean hasTag()- Specified by:
hasTagin interfaceWrappedMessage.ValueOrTag<T>
-
getTag
public int getTag()- Specified by:
getTagin interfaceWrappedMessage.ValueOrTag<T>
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with thecomparemethod from their corresponding wrapper classes. -
tag
public int tag()Returns the value of thetagrecord component.- Returns:
- the value of the
tagrecord component
-