Record Class PacketIdentification
java.lang.Object
java.lang.Record
net.minecraft.util.profiling.jfr.stats.PacketIdentification
-
Field Summary
-
Constructor Summary
ConstructorDescriptionPacketIdentification
(String direction, String protocolId, String packetId) Creates an instance of aPacketIdentification
record class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thedirection
record component.final boolean
Indicates whether some other object is "equal to" this one.static PacketIdentification
from
(RecordedEvent p_326266_) final int
hashCode()
Returns a hash code value for this object.packetId()
Returns the value of thepacketId
record component.Returns the value of theprotocolId
record component.final String
toString()
Returns a string representation of this record class.
-
Field Details
-
direction
The field for thedirection
record component. -
protocolId
The field for theprotocolId
record component. -
packetId
The field for thepacketId
record component.
-
-
Constructor Details
-
PacketIdentification
Creates an instance of aPacketIdentification
record class.- Parameters:
direction
- the value for thedirection
record componentprotocolId
- the value for theprotocolId
record componentpacketId
- the value for thepacketId
record component
-
-
Method Details
-
from
-
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. All components in this record class are compared withObjects::equals(Object,Object)
. -
direction
Returns the value of thedirection
record component.- Returns:
- the value of the
direction
record component
-
protocolId
Returns the value of theprotocolId
record component.- Returns:
- the value of the
protocolId
record component
-
packetId
Returns the value of thepacketId
record component.- Returns:
- the value of the
packetId
record component
-