Record Class PlayerInfoUpdatePacket.Entry
java.lang.Object
java.lang.Record
net.minestom.server.network.packet.server.play.PlayerInfoUpdatePacket.Entry
- Enclosing class:
PlayerInfoUpdatePacket
public static record PlayerInfoUpdatePacket.Entry(UUID uuid, String username, List<PlayerInfoUpdatePacket.Property> properties, boolean listed, int latency, GameMode gameMode, @Nullable Component displayName, @Nullable ChatSession chatSession)
extends Record
-
Constructor Summary
ConstructorDescriptionEntry
(UUID uuid, String username, List<PlayerInfoUpdatePacket.Property> properties, boolean listed, int latency, GameMode gameMode, @Nullable Component displayName, @Nullable ChatSession chatSession) Creates an instance of aEntry
record class. -
Method Summary
Modifier and TypeMethodDescription@Nullable ChatSession
Returns the value of thechatSession
record component.@Nullable Component
Returns the value of thedisplayName
record component.final boolean
Indicates whether some other object is "equal to" this one.gameMode()
Returns the value of thegameMode
record component.final int
hashCode()
Returns a hash code value for this object.int
latency()
Returns the value of thelatency
record component.boolean
listed()
Returns the value of thelisted
record component.Returns the value of theproperties
record component.final String
toString()
Returns a string representation of this record class.username()
Returns the value of theusername
record component.uuid()
Returns the value of theuuid
record component.
-
Constructor Details
-
Entry
public Entry(UUID uuid, String username, List<PlayerInfoUpdatePacket.Property> properties, boolean listed, int latency, GameMode gameMode, @Nullable @Nullable Component displayName, @Nullable @Nullable ChatSession chatSession) Creates an instance of aEntry
record class.- Parameters:
uuid
- the value for theuuid
record componentusername
- the value for theusername
record componentproperties
- the value for theproperties
record componentlisted
- the value for thelisted
record componentlatency
- the value for thelatency
record componentgameMode
- the value for thegameMode
record componentdisplayName
- the value for thedisplayName
record componentchatSession
- the value for thechatSession
record component
-
-
Method Details
-
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 '=='. -
uuid
Returns the value of theuuid
record component.- Returns:
- the value of the
uuid
record component
-
username
Returns the value of theusername
record component.- Returns:
- the value of the
username
record component
-
properties
Returns the value of theproperties
record component.- Returns:
- the value of the
properties
record component
-
listed
public boolean listed()Returns the value of thelisted
record component.- Returns:
- the value of the
listed
record component
-
latency
public int latency()Returns the value of thelatency
record component.- Returns:
- the value of the
latency
record component
-
gameMode
Returns the value of thegameMode
record component.- Returns:
- the value of the
gameMode
record component
-
displayName
Returns the value of thedisplayName
record component.- Returns:
- the value of the
displayName
record component
-
chatSession
Returns the value of thechatSession
record component.- Returns:
- the value of the
chatSession
record component
-