Record Class CollectionCountsPredicate.Single<T, P extends Predicate<T>>
java.lang.Object
java.lang.Record
net.minecraft.advancements.criterion.CollectionCountsPredicate.Single<T,P>
- All Implemented Interfaces:
Predicate<Iterable<? extends T>>, CollectionCountsPredicate<T,P>
- Enclosing interface:
CollectionCountsPredicate<T, P extends Predicate<T>>
public static record CollectionCountsPredicate.Single<T, P extends Predicate<T>>(CollectionCountsPredicate.Entry<T, P extends Predicate<T>> entry)
extends Record
implements CollectionCountsPredicate<T,P>
-
Nested Class Summary
Nested classes/interfaces inherited from interface CollectionCountsPredicate
CollectionCountsPredicate.Entry<T,P>, CollectionCountsPredicate.Multiple<T, P>, CollectionCountsPredicate.Single<T, P>, CollectionCountsPredicate.Zero<T, P> -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final CollectionCountsPredicate.Entry<T, P> The field for theentryrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionSingle(CollectionCountsPredicate.Entry<T, P> entry) Creates an instance of aSinglerecord class. -
Method Summary
Modifier and TypeMethodDescriptionentry()Returns the value of theentryrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanfinal StringtoString()Returns a string representation of this record class.unpack()
-
Field Details
-
entry
The field for theentryrecord component.
-
-
Constructor Details
-
Single
Creates an instance of aSinglerecord class.- Parameters:
entry- the value for theentryrecord component
-
-
Method Details
-
test
-
unpack
-
toString
-
hashCode
-
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). -
entry
Returns the value of theentryrecord component.- Returns:
- the value of the
entryrecord component
-