Package net.minecraft.command.argument
Record Class RegistryEntryPredicateArgumentType.EntryBased<T>
java.lang.Object
java.lang.Record
net.minecraft.command.argument.RegistryEntryPredicateArgumentType.EntryBased<T>
- Record Components:
value-
- All Implemented Interfaces:
Predicate<RegistryEntry<T>>,RegistryEntryPredicateArgumentType.EntryPredicate<T>
- Enclosing class:
RegistryEntryPredicateArgumentType<T>
private static record RegistryEntryPredicateArgumentType.EntryBased<T>(RegistryEntry.Reference<T> value)
extends Record
implements RegistryEntryPredicateArgumentType.EntryPredicate<T>
- Mappings:
Namespace Name named net/minecraft/command/argument/RegistryEntryPredicateArgumentType$EntryBasedintermediary net/minecraft/class_7737$class_7740official fw$bnamed valueintermediary comp_1023official a
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final RegistryEntry.Reference<T> The field for thevaluerecord component. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionasString()final booleanIndicates whether some other object is "equal to" this one.com.mojang.datafixers.util.Either<RegistryEntry.Reference<T>, RegistryEntryList.Named<T>> getEntry()final inthashCode()Returns a hash code value for this object.booleantest(RegistryEntry<T> registryEntry) final StringtoString()Returns a string representation of this record class.tryCast(RegistryKey<? extends Registry<E>> registryRef) value()Returns the value of thevaluerecord component.
-
Field Details
-
value
The field for thevaluerecord component.
-
-
Constructor Details
-
EntryBased
EntryBased(RegistryEntry.Reference<T> reference)
-
-
Method Details
-
getEntry
public com.mojang.datafixers.util.Either<RegistryEntry.Reference<T>,RegistryEntryList.Named<T>> getEntry()- Specified by:
getEntryin interfaceRegistryEntryPredicateArgumentType.EntryPredicate<T>- Mappings:
Namespace Name Mixin selector named getEntryLnet/minecraft/command/argument/RegistryEntryPredicateArgumentType$EntryPredicate;getEntry()Lcom/mojang/datafixers/util/Either;intermediary method_45647Lnet/minecraft/class_7737$class_7741;method_45647()Lcom/mojang/datafixers/util/Either;official aLfw$c;a()Lcom/mojang/datafixers/util/Either;
-
tryCast
public <E> Optional<RegistryEntryPredicateArgumentType.EntryPredicate<E>> tryCast(RegistryKey<? extends Registry<E>> registryRef) - Specified by:
tryCastin interfaceRegistryEntryPredicateArgumentType.EntryPredicate<T>- Mappings:
Namespace Name Mixin selector named tryCastLnet/minecraft/command/argument/RegistryEntryPredicateArgumentType$EntryPredicate;tryCast(Lnet/minecraft/registry/RegistryKey;)Ljava/util/Optional;intermediary method_45648Lnet/minecraft/class_7737$class_7741;method_45648(Lnet/minecraft/class_5321;)Ljava/util/Optional;official aLfw$c;a(Lakq;)Ljava/util/Optional;
-
test
- Specified by:
testin interfacePredicate<T>- Mappings:
Namespace Name Mixin selector named testLnet/minecraft/command/argument/RegistryEntryPredicateArgumentType$EntryBased;test(Lnet/minecraft/registry/entry/RegistryEntry;)Zintermediary method_45649Lnet/minecraft/class_7737$class_7740;method_45649(Lnet/minecraft/class_6880;)Zofficial aLfw$b;a(Ljm;)Z
-
asString
- Specified by:
asStringin interfaceRegistryEntryPredicateArgumentType.EntryPredicate<T>- Mappings:
Namespace Name Mixin selector named asStringLnet/minecraft/command/argument/RegistryEntryPredicateArgumentType$EntryPredicate;asString()Ljava/lang/String;intermediary method_45650Lnet/minecraft/class_7737$class_7741;method_45650()Ljava/lang/String;official bLfw$c;b()Ljava/lang/String;
-
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). -
value
Returns the value of thevaluerecord component.- Returns:
- the value of the
valuerecord component
-