Record Class TwoPhaseCommitInterceptor.MapEntry
java.lang.Object
java.lang.Record
org.apache.catalina.tribes.group.interceptors.TwoPhaseCommitInterceptor.MapEntry
- Enclosing class:
TwoPhaseCommitInterceptor
public static record TwoPhaseCommitInterceptor.MapEntry(ChannelMessage msg, UniqueId id, long timestamp)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionMapEntry(ChannelMessage msg, UniqueId id, long timestamp) Creates an instance of aMapEntryrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.booleanexpired(long now, long expiration) final inthashCode()Returns a hash code value for this object.id()Returns the value of theidrecord component.msg()Returns the value of themsgrecord component.longReturns the value of thetimestamprecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
MapEntry
Creates an instance of aMapEntryrecord class.- Parameters:
msg- the value for themsgrecord componentid- the value for theidrecord componenttimestamp- the value for thetimestamprecord component
-
-
Method Details
-
expired
public boolean expired(long now, long expiration) -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
msg
Returns the value of themsgrecord component.- Returns:
- the value of the
msgrecord component
-
id
Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
timestamp
public long timestamp()Returns the value of thetimestamprecord component.- Returns:
- the value of the
timestamprecord component
-