Record Class ClientboundPlayerChatPacket
java.lang.Object
java.lang.Record
net.minecraft.network.protocol.game.ClientboundPlayerChatPacket
- All Implemented Interfaces:
- Packet<ClientGamePacketListener>
public record ClientboundPlayerChatPacket(UUID sender, int index, @Nullable MessageSignature signature, SignedMessageBody.Packed body, @Nullable Component unsignedContent, FilterMask filterMask, ChatType.BoundNetwork chatType)
extends Record
implements Packet<ClientGamePacketListener>
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprivate final SignedMessageBody.PackedThe field for thebodyrecord component.private final ChatType.BoundNetworkThe field for thechatTyperecord component.private final FilterMaskThe field for thefilterMaskrecord component.private final intThe field for theindexrecord component.private final UUIDThe field for thesenderrecord component.private final MessageSignatureThe field for thesignaturerecord component.private final ComponentThe field for theunsignedContentrecord component.
- 
Constructor SummaryConstructorsConstructorDescriptionClientboundPlayerChatPacket(UUID sender, int index, MessageSignature signature, SignedMessageBody.Packed body, Component unsignedContent, FilterMask filterMask, ChatType.BoundNetwork chatType) Creates an instance of aClientboundPlayerChatPacketrecord class.ClientboundPlayerChatPacket(FriendlyByteBuf p_237741_) 
- 
Method SummaryModifier and TypeMethodDescriptionbody()Returns the value of thebodyrecord component.chatType()Returns the value of thechatTyperecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of thefilterMaskrecord component.voidhandle(ClientGamePacketListener p_237759_) final inthashCode()Returns a hash code value for this object.intindex()Returns the value of theindexrecord component.booleansender()Returns the value of thesenderrecord component.Returns the value of thesignaturerecord component.final StringtoString()Returns a string representation of this record class.Returns the value of theunsignedContentrecord component.voidwrite(FriendlyByteBuf p_237755_) Methods inherited from class java.lang.Objectclone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.network.protocol.PacketnextProtocol
- 
Field Details- 
senderThe field for thesenderrecord component.
- 
indexprivate final int indexThe field for theindexrecord component.
- 
signatureThe field for thesignaturerecord component.
- 
bodyThe field for thebodyrecord component.
- 
unsignedContentThe field for theunsignedContentrecord component.
- 
filterMaskThe field for thefilterMaskrecord component.
- 
chatTypeThe field for thechatTyperecord component.
 
- 
- 
Constructor Details- 
ClientboundPlayerChatPacket
- 
ClientboundPlayerChatPacketpublic ClientboundPlayerChatPacket(UUID sender, int index, @Nullable MessageSignature signature, SignedMessageBody.Packed body, @Nullable Component unsignedContent, FilterMask filterMask, ChatType.BoundNetwork chatType) Creates an instance of aClientboundPlayerChatPacketrecord class.- Parameters:
- sender- the value for the- senderrecord component
- index- the value for the- indexrecord component
- signature- the value for the- signaturerecord component
- body- the value for the- bodyrecord component
- unsignedContent- the value for the- unsignedContentrecord component
- filterMask- the value for the- filterMaskrecord component
- chatType- the value for the- chatTyperecord component
 
 
- 
- 
Method Details- 
write- Specified by:
- writein interface- Packet<ClientGamePacketListener>
 
- 
handle- Specified by:
- handlein interface- Packet<ClientGamePacketListener>
 
- 
isSkippablepublic boolean isSkippable()- Specified by:
- isSkippablein interface- Packet<ClientGamePacketListener>
 
- 
toStringReturns 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.
- 
hashCodepublic 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.
- 
equalsIndicates 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 '=='.
- 
senderReturns the value of thesenderrecord component.- Returns:
- the value of the senderrecord component
 
- 
indexpublic int index()Returns the value of theindexrecord component.- Returns:
- the value of the indexrecord component
 
- 
signatureReturns the value of thesignaturerecord component.- Returns:
- the value of the signaturerecord component
 
- 
bodyReturns the value of thebodyrecord component.- Returns:
- the value of the bodyrecord component
 
- 
unsignedContentReturns the value of theunsignedContentrecord component.- Returns:
- the value of the unsignedContentrecord component
 
- 
filterMaskReturns the value of thefilterMaskrecord component.- Returns:
- the value of the filterMaskrecord component
 
- 
chatTypeReturns the value of thechatTyperecord component.- Returns:
- the value of the chatTyperecord component
 
 
-