Package net.minecraft.network.message
Record Class MessageSender
java.lang.Object
java.lang.Record
net.minecraft.network.message.MessageSender
- Record Components:
profileId-name-targetName-
The sender, or the source, of a message.
An instance can be obtained via Entity.asMessageSender().
- Mappings:
Namespace Name official rhintermediary net/minecraft/class_7436named net/minecraft/network/message/MessageSenderofficial aintermediary comp_756named profileIdofficial bintermediary comp_757named nameofficial cintermediary comp_791named targetName
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final TextThe field for thenamerecord component.private final UUIDThe field for theprofileIdrecord component.The field for thetargetNamerecord component. -
Constructor Summary
ConstructorsConstructorDescriptionMessageSender(UUID profileId, Text name) MessageSender(UUID uUID, Text text, @Nullable Text text2) -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanname()Returns the value of thenamerecord component.static MessageSenderReturns the value of theprofileIdrecord component.Returns the value of thetargetNamerecord component.final StringtoString()Returns a string representation of this record class.withTargetName(Text targetName) voidwrite(PacketByteBuf buf)
-
Field Details
-
profileId
The field for theprofileIdrecord component. -
name
The field for thenamerecord component. -
targetName
The field for thetargetNamerecord component.
-
-
Constructor Details
-
MessageSender
- Mappings:
Namespace Name Mixin selector official <init>Lrh;<init>(Ljava/util/UUID;Lrm;)Vintermediary <init>Lnet/minecraft/class_7436;<init>(Ljava/util/UUID;Lnet/minecraft/class_2561;)Vnamed <init>Lnet/minecraft/network/message/MessageSender;<init>(Ljava/util/UUID;Lnet/minecraft/text/Text;)V
-
MessageSender
- Mappings:
Namespace Name Mixin selector official <init>Lrh;<init>(Lqx;)Vintermediary <init>Lnet/minecraft/class_7436;<init>(Lnet/minecraft/class_2540;)Vnamed <init>Lnet/minecraft/network/message/MessageSender;<init>(Lnet/minecraft/network/PacketByteBuf;)V
-
MessageSender
-
-
Method Details
-
of
- Mappings:
Namespace Name Mixin selector official aLrh;a(Lrm;)Lrh;intermediary method_43841Lnet/minecraft/class_7436;method_43841(Lnet/minecraft/class_2561;)Lnet/minecraft/class_7436;named ofLnet/minecraft/network/message/MessageSender;of(Lnet/minecraft/text/Text;)Lnet/minecraft/network/message/MessageSender;
-
write
- Mappings:
Namespace Name Mixin selector official aLrh;a(Lqx;)Vintermediary method_43625Lnet/minecraft/class_7436;method_43625(Lnet/minecraft/class_2540;)Vnamed writeLnet/minecraft/network/message/MessageSender;write(Lnet/minecraft/network/PacketByteBuf;)V
-
withTargetName
- Mappings:
Namespace Name Mixin selector official bLrh;b(Lrm;)Lrh;intermediary method_43842Lnet/minecraft/class_7436;method_43842(Lnet/minecraft/class_2561;)Lnet/minecraft/class_7436;named withTargetNameLnet/minecraft/network/message/MessageSender;withTargetName(Lnet/minecraft/text/Text;)Lnet/minecraft/network/message/MessageSender;
-
withoutProfileId
- Mappings:
Namespace Name Mixin selector official aLrh;a()Lrh;intermediary method_44778Lnet/minecraft/class_7436;method_44778()Lnet/minecraft/class_7436;named withoutProfileIdLnet/minecraft/network/message/MessageSender;withoutProfileId()Lnet/minecraft/network/message/MessageSender;
-
hasProfileId
public boolean hasProfileId()- Mappings:
Namespace Name Mixin selector official bLrh;b()Zintermediary method_44744Lnet/minecraft/class_7436;method_44744()Znamed hasProfileIdLnet/minecraft/network/message/MessageSender;hasProfileId()Z
-
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). -
profileId
Returns the value of theprofileIdrecord component.- Returns:
- the value of the
profileIdrecord component
-
name
Returns the value of thenamerecord component.- Returns:
- the value of the
namerecord component
-
targetName
Returns the value of thetargetNamerecord component.- Returns:
- the value of the
targetNamerecord component
-