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 net.kyori.adventure.text.Component displayName, @Nullable ChatSession chatSession)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionEntry(UUID uuid, String username, List<PlayerInfoUpdatePacket.Property> properties, boolean listed, int latency, GameMode gameMode, @Nullable net.kyori.adventure.text.Component displayName, @Nullable ChatSession chatSession) Creates an instance of aEntryrecord class. -
Method Summary
Modifier and TypeMethodDescription@Nullable ChatSessionReturns the value of thechatSessionrecord component.@Nullable net.kyori.adventure.text.ComponentReturns the value of thedisplayNamerecord component.final booleanIndicates whether some other object is "equal to" this one.gameMode()Returns the value of thegameModerecord component.final inthashCode()Returns a hash code value for this object.intlatency()Returns the value of thelatencyrecord component.booleanlisted()Returns the value of thelistedrecord component.Returns the value of thepropertiesrecord component.final StringtoString()Returns a string representation of this record class.username()Returns the value of theusernamerecord component.uuid()Returns the value of theuuidrecord component.
-
Constructor Details
-
Entry
public Entry(UUID uuid, String username, List<PlayerInfoUpdatePacket.Property> properties, boolean listed, int latency, GameMode gameMode, @Nullable @Nullable net.kyori.adventure.text.Component displayName, @Nullable @Nullable ChatSession chatSession) Creates an instance of aEntryrecord class.- Parameters:
uuid- the value for theuuidrecord componentusername- the value for theusernamerecord componentproperties- the value for thepropertiesrecord componentlisted- the value for thelistedrecord componentlatency- the value for thelatencyrecord componentgameMode- the value for thegameModerecord componentdisplayName- the value for thedisplayNamerecord componentchatSession- the value for thechatSessionrecord 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 theuuidrecord component.- Returns:
- the value of the
uuidrecord component
-
username
Returns the value of theusernamerecord component.- Returns:
- the value of the
usernamerecord component
-
properties
Returns the value of thepropertiesrecord component.- Returns:
- the value of the
propertiesrecord component
-
listed
public boolean listed()Returns the value of thelistedrecord component.- Returns:
- the value of the
listedrecord component
-
latency
public int latency()Returns the value of thelatencyrecord component.- Returns:
- the value of the
latencyrecord component
-
gameMode
Returns the value of thegameModerecord component.- Returns:
- the value of the
gameModerecord component
-
displayName
@Nullable public @Nullable net.kyori.adventure.text.Component displayName()Returns the value of thedisplayNamerecord component.- Returns:
- the value of the
displayNamerecord component
-
chatSession
Returns the value of thechatSessionrecord component.- Returns:
- the value of the
chatSessionrecord component
-