Package net.minecraft.command.argument
Record Class RegistryPredicateArgumentType.TagBased<T>
java.lang.Object
java.lang.Record
net.minecraft.command.argument.RegistryPredicateArgumentType.TagBased<T>
- Record Components:
key
-
- All Implemented Interfaces:
Predicate<RegistryEntry<T>>
,RegistryPredicateArgumentType.RegistryPredicate<T>
- Enclosing class:
RegistryPredicateArgumentType<T>
private static record RegistryPredicateArgumentType.TagBased<T>(TagKey<T> key)
extends Record
implements RegistryPredicateArgumentType.RegistryPredicate<T>
- Mappings:
Namespace Name official es$d
intermediary net/minecraft/class_7066$class_7070
named net/minecraft/command/argument/RegistryPredicateArgumentType$TagBased
official a
intermediary comp_523
named key
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionasString()
final boolean
Indicates whether some other object is "equal to" this one.com.mojang.datafixers.util.Either<RegistryKey<T>,
TagKey<T>> getKey()
final int
hashCode()
Returns a hash code value for this object.key()
Returns the value of thekey
record component.boolean
test
(RegistryEntry<T> registryEntry) final String
toString()
Returns a string representation of this record class.tryCast
(RegistryKey<? extends Registry<E>> registryRef)
-
Field Details
-
key
The field for thekey
record component.
-
-
Constructor Details
-
TagBased
-
-
Method Details
-
getKey
- Specified by:
getKey
in interfaceRegistryPredicateArgumentType.RegistryPredicate<T>
- Mappings:
Namespace Name Mixin selector official a
Les$c;a()Lcom/mojang/datafixers/util/Either;
intermediary method_41173
Lnet/minecraft/class_7066$class_7068;method_41173()Lcom/mojang/datafixers/util/Either;
named getKey
Lnet/minecraft/command/argument/RegistryPredicateArgumentType$RegistryPredicate;getKey()Lcom/mojang/datafixers/util/Either;
-
tryCast
public <E> Optional<RegistryPredicateArgumentType.RegistryPredicate<E>> tryCast(RegistryKey<? extends Registry<E>> registryRef) - Specified by:
tryCast
in interfaceRegistryPredicateArgumentType.RegistryPredicate<T>
- Mappings:
Namespace Name Mixin selector official a
Les$c;a(Lacp;)Ljava/util/Optional;
intermediary method_41175
Lnet/minecraft/class_7066$class_7068;method_41175(Lnet/minecraft/class_5321;)Ljava/util/Optional;
named tryCast
Lnet/minecraft/command/argument/RegistryPredicateArgumentType$RegistryPredicate;tryCast(Lnet/minecraft/registry/RegistryKey;)Ljava/util/Optional;
-
test
- Specified by:
test
in interfacePredicate<T>
- Mappings:
Namespace Name Mixin selector official a
Les$d;a(Lhe;)Z
intermediary method_41180
Lnet/minecraft/class_7066$class_7070;method_41180(Lnet/minecraft/class_6880;)Z
named test
Lnet/minecraft/command/argument/RegistryPredicateArgumentType$TagBased;test(Lnet/minecraft/registry/entry/RegistryEntry;)Z
-
asString
- Specified by:
asString
in interfaceRegistryPredicateArgumentType.RegistryPredicate<T>
- Mappings:
Namespace Name Mixin selector official b
Les$c;b()Ljava/lang/String;
intermediary method_41176
Lnet/minecraft/class_7066$class_7068;method_41176()Ljava/lang/String;
named asString
Lnet/minecraft/command/argument/RegistryPredicateArgumentType$RegistryPredicate;asString()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)
. -
key
Returns the value of thekey
record component.- Returns:
- the value of the
key
record component
-