Package net.minecraft.text
Record Class EntityNbtText
java.lang.Object
java.lang.Record
net.minecraft.text.EntityNbtText
- Record Components:
rawSelector-selector-
- All Implemented Interfaces:
class_7419
public record EntityNbtText(String rawSelector, @Nullable EntitySelector selector)
extends Record
implements class_7419
- Mappings:
Namespace Name official rjintermediary net/minecraft/class_2576named net/minecraft/text/EntityNbtTextofficial aintermediary comp_735named rawSelectorofficial bintermediary comp_736named selector
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final StringThe field for therawSelectorrecord component.private final @Nullable EntitySelectorThe field for theselectorrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionEntityNbtText(String rawPath) EntityNbtText(String rawPath, @Nullable EntitySelector entitySelector) -
Method Summary
Modifier and TypeMethodDescriptionbooleanIndicates whether some other object is "equal to" this one.inthashCode()Returns a hash code value for this object.private static @Nullable EntitySelectorparseSelector(String rawSelector) Returns the value of therawSelectorrecord component.selector()Returns the value of theselectorrecord component.toNbt(ServerCommandSource serverCommandSource) toString()Returns a string representation of this record class.
-
Field Details
-
rawSelector
The field for therawSelectorrecord component. -
selector
The field for theselectorrecord component.
-
-
Constructor Details
-
EntityNbtText
- Mappings:
Namespace Name Mixin selector official <init>Lrj;<init>(Ljava/lang/String;)Vintermediary <init>Lnet/minecraft/class_2576;<init>(Ljava/lang/String;)Vnamed <init>Lnet/minecraft/text/EntityNbtText;<init>(Ljava/lang/String;)V
-
EntityNbtText
- Mappings:
Namespace Name Mixin selector official <init>Lrj;<init>(Ljava/lang/String;Lfs;)Vintermediary <init>Lnet/minecraft/class_2576;<init>(Ljava/lang/String;Lnet/minecraft/class_2300;)Vnamed <init>Lnet/minecraft/text/EntityNbtText;<init>(Ljava/lang/String;Lnet/minecraft/command/EntitySelector;)V
-
-
Method Details
-
parseSelector
- Mappings:
Namespace Name Mixin selector official aLrj;a(Ljava/lang/String;)Lfs;intermediary method_10923Lnet/minecraft/class_2576;method_10923(Ljava/lang/String;)Lnet/minecraft/class_2300;named parseSelectorLnet/minecraft/text/EntityNbtText;parseSelector(Ljava/lang/String;)Lnet/minecraft/command/EntitySelector;
-
toNbt
public Stream<NbtCompound> toNbt(ServerCommandSource serverCommandSource) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Specified by:
toNbtin interfaceclass_7419- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException- Mappings:
Namespace Name Mixin selector official getDataLri;getData(Ldq;)Ljava/util/stream/Stream;intermediary method_10916Lnet/minecraft/class_7419;method_10916(Lnet/minecraft/class_2168;)Ljava/util/stream/Stream;named toNbtLnet/minecraft/class_7419;toNbt(Lnet/minecraft/server/command/ServerCommandSource;)Ljava/util/stream/Stream;
-
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. -
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). -
hashCode
public int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
rawSelector
Returns the value of therawSelectorrecord component.- Returns:
- the value of the
rawSelectorrecord component
-
selector
Returns the value of theselectorrecord component.- Returns:
- the value of the
selectorrecord component
-