Record Class PacketIdentification
java.lang.Object
java.lang.Record
net.minecraft.util.profiling.jfr.stats.PacketIdentification
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionPacketIdentification(String direction, String protocolId, String packetId) Creates an instance of aPacketIdentificationrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thedirectionrecord component.final booleanIndicates whether some other object is "equal to" this one.static PacketIdentificationfrom(RecordedEvent p_333273_) final inthashCode()Returns a hash code value for this object.packetId()Returns the value of thepacketIdrecord component.Returns the value of theprotocolIdrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
direction
The field for thedirectionrecord component. -
protocolId
The field for theprotocolIdrecord component. -
packetId
The field for thepacketIdrecord component.
-
-
Constructor Details
-
PacketIdentification
Creates an instance of aPacketIdentificationrecord class.- Parameters:
direction- the value for thedirectionrecord componentprotocolId- the value for theprotocolIdrecord componentpacketId- the value for thepacketIdrecord 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 thedirectionrecord component.- Returns:
- the value of the
directionrecord component
-
protocolId
Returns the value of theprotocolIdrecord component.- Returns:
- the value of the
protocolIdrecord component
-
packetId
Returns the value of thepacketIdrecord component.- Returns:
- the value of the
packetIdrecord component
-