Package net.minecraft.client.report.log
Record Class ReceivedMessage.ChatMessage
java.lang.Object
java.lang.Record
net.minecraft.client.report.log.ReceivedMessage.ChatMessage
- Record Components:
profile-displayName-message-trustStatus-
- All Implemented Interfaces:
ChatLogEntry,HeaderEntry,ReceivedMessage
- Enclosing interface:
ReceivedMessage
@Environment(CLIENT)
public static record ReceivedMessage.ChatMessage(com.mojang.authlib.GameProfile profile, Text displayName, SignedMessage message, MessageTrustStatus trustStatus)
extends Record
implements ReceivedMessage, HeaderEntry
A chat message received by the client.
- Mappings:
Namespace Name official evj$aintermediary net/minecraft/class_7557$class_7558named net/minecraft/client/report/log/ReceivedMessage$ChatMessageofficial aintermediary comp_868named profileofficial bintermediary comp_869named displayNameofficial cintermediary comp_870named messageofficial dintermediary comp_905named trustStatus
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.client.report.log.HeaderEntry
HeaderEntry.ImplNested classes/interfaces inherited from interface net.minecraft.client.report.log.ReceivedMessage
ReceivedMessage.ChatMessage, ReceivedMessage.GameMessage -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final DateTimeFormatterprivate final TextThe field for thedisplayNamerecord component.private final SignedMessageThe field for themessagerecord component.private final com.mojang.authlib.GameProfileThe field for theprofilerecord component.private final MessageTrustStatusThe field for thetrustStatusrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionChatMessage(com.mojang.authlib.GameProfile gameProfile, Text text, SignedMessage signedMessage, MessageTrustStatus messageTrustStatus) -
Method Summary
Modifier and TypeMethodDescriptionbyte[]Returns the value of thedisplayNamerecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the content of the message.private TextReturns the formatted timestamp text of this message.Returns the heading text used by Chat Selection screen.Returns the narration of the message (by default, the content).Returns the UUID of the sender.final inthashCode()Returns a hash code value for this object.header()booleanisSentFrom(UUID uuid) Returns whether the sender's UUID equalsuuid.message()Returns the value of themessagerecord component.com.mojang.authlib.GameProfileprofile()Returns the value of theprofilerecord component.final StringtoString()Returns a string representation of this record class.Returns the value of thetrustStatusrecord component.
-
Field Details
-
profile
private final com.mojang.authlib.GameProfile profileThe field for theprofilerecord component. -
displayName
The field for thedisplayNamerecord component. -
message
The field for themessagerecord component. -
trustStatus
The field for thetrustStatusrecord component. -
DATE_TIME_FORMATTER
- Mappings:
Namespace Name Mixin selector official eLevj$a;e:Ljava/time/format/DateTimeFormatter;intermediary field_39637Lnet/minecraft/class_7557$class_7558;field_39637:Ljava/time/format/DateTimeFormatter;named DATE_TIME_FORMATTERLnet/minecraft/client/report/log/ReceivedMessage$ChatMessage;DATE_TIME_FORMATTER:Ljava/time/format/DateTimeFormatter;
-
-
Constructor Details
-
ChatMessage
public ChatMessage(com.mojang.authlib.GameProfile gameProfile, Text text, SignedMessage signedMessage, MessageTrustStatus messageTrustStatus)
-
-
Method Details
-
getContent
Returns the content of the message.- Specified by:
getContentin interfaceReceivedMessage- Returns:
- the content of the message
- Mappings:
Namespace Name Mixin selector official aLevj;a()Lrq;intermediary method_44551Lnet/minecraft/class_7557;method_44551()Lnet/minecraft/class_2561;named getContentLnet/minecraft/client/report/log/ReceivedMessage;getContent()Lnet/minecraft/text/Text;
-
getNarration
Returns the narration of the message (by default, the content).- Specified by:
getNarrationin interfaceReceivedMessage- Returns:
- the narration of the message (by default, the content)
- Mappings:
Namespace Name Mixin selector official bLevj;b()Lrq;intermediary method_44555Lnet/minecraft/class_7557;method_44555()Lnet/minecraft/class_2561;named getNarrationLnet/minecraft/client/report/log/ReceivedMessage;getNarration()Lnet/minecraft/text/Text;
-
getHeadingText
Returns the heading text used by Chat Selection screen.The text contains the sender's display name and the formatted timestamp.
- Returns:
- the heading text used by Chat Selection screen
- Mappings:
Namespace Name Mixin selector official cLevj$a;c()Lrq;intermediary method_44556Lnet/minecraft/class_7557$class_7558;method_44556()Lnet/minecraft/class_2561;named getHeadingTextLnet/minecraft/client/report/log/ReceivedMessage$ChatMessage;getHeadingText()Lnet/minecraft/text/Text;
-
getFormattedTimestamp
Returns the formatted timestamp text of this message.- Returns:
- the formatted timestamp text of this message
- Mappings:
Namespace Name Mixin selector official lLevj$a;l()Lrq;intermediary method_44558Lnet/minecraft/class_7557$class_7558;method_44558()Lnet/minecraft/class_2561;named getFormattedTimestampLnet/minecraft/client/report/log/ReceivedMessage$ChatMessage;getFormattedTimestamp()Lnet/minecraft/text/Text;
-
isSentFrom
Returns whether the sender's UUID equalsuuid.- Specified by:
isSentFromin interfaceReceivedMessage- Returns:
- whether the sender's UUID equals
uuid - Mappings:
Namespace Name Mixin selector official aLevj;a(Ljava/util/UUID;)Zintermediary method_44553Lnet/minecraft/class_7557;method_44553(Ljava/util/UUID;)Znamed isSentFromLnet/minecraft/client/report/log/ReceivedMessage;isSentFrom(Ljava/util/UUID;)Z
-
header
- Specified by:
headerin interfaceHeaderEntry- Mappings:
Namespace Name Mixin selector official dLevk;d()Lsh;intermediary comp_960Lnet/minecraft/class_7630;comp_960()Lnet/minecraft/class_7614;named headerLnet/minecraft/client/report/log/HeaderEntry;header()Lnet/minecraft/network/message/MessageHeader;
-
bodyDigest
public byte[] bodyDigest()- Specified by:
bodyDigestin interfaceHeaderEntry- Mappings:
Namespace Name Mixin selector official eLevk;e()[Bintermediary comp_962Lnet/minecraft/class_7630;comp_962()[Bnamed bodyDigestLnet/minecraft/client/report/log/HeaderEntry;bodyDigest()[B
-
headerSignature
- Specified by:
headerSignaturein interfaceHeaderEntry- Mappings:
Namespace Name Mixin selector official fLevk;f()Lrz;intermediary comp_961Lnet/minecraft/class_7630;comp_961()Lnet/minecraft/class_7469;named headerSignatureLnet/minecraft/client/report/log/HeaderEntry;headerSignature()Lnet/minecraft/network/message/MessageSignatureData;
-
getSenderUuid
Returns the UUID of the sender.- Returns:
- the UUID of the sender
- Mappings:
Namespace Name Mixin selector official gLevj$a;g()Ljava/util/UUID;intermediary method_44557Lnet/minecraft/class_7557$class_7558;method_44557()Ljava/util/UUID;named getSenderUuidLnet/minecraft/client/report/log/ReceivedMessage$ChatMessage;getSenderUuid()Ljava/util/UUID;
-
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). -
profile
public com.mojang.authlib.GameProfile profile()Returns the value of theprofilerecord component.- Returns:
- the value of the
profilerecord component
-
displayName
Returns the value of thedisplayNamerecord component.- Returns:
- the value of the
displayNamerecord component
-
message
Returns the value of themessagerecord component.- Returns:
- the value of the
messagerecord component
-
trustStatus
Returns the value of thetrustStatusrecord component.- Returns:
- the value of the
trustStatusrecord component
-