Interface MinecraftPredicate<C extends MinecraftPredicateContext>
- Type Parameters:
C- the predicate context.
- All Superinterfaces:
Predicate<C>
- All Known Subinterfaces:
ChargeTypePredicate,CustomModelDataPredicate.FlagPredicate,CustomModelDataPredicate.StringPredicate,DimensionPredicate,HasComponentPredicate,RangeDispatchPredicate,TrimMaterialPredicate
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface
public interface MinecraftPredicate<C extends MinecraftPredicateContext>
extends Predicate<C>
A predicate for a
MinecraftPredicateContext.
This is used to determine if a CustomItemDefinition should be used. While this does
allow you to define your own predicates with custom checks, it is recommended to use commonly defined predicates and predicate creators when possible,
since these support conflict detection among other benefits. See CustomItemDefinition.predicates().
- Since:
- 2.9.3
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptiondefault @NonNull MinecraftPredicate<C>default @NonNull MinecraftPredicate<C>negate()default @NonNull MinecraftPredicate<C>
-
Method Details
-
and
- Specified by:
andin interfacePredicate<C extends MinecraftPredicateContext>
-
negate
- Specified by:
negatein interfacePredicate<C extends MinecraftPredicateContext>
-
or
- Specified by:
orin interfacePredicate<C extends MinecraftPredicateContext>
-