Package net.minecraft.inventory
Record Class ItemSource.Filter
java.lang.Object
java.lang.Record
net.minecraft.inventory.ItemSource.Filter
- Record Components:
slots-filter-
- All Implemented Interfaces:
ItemSource
- Enclosing interface:
ItemSource
public static record ItemSource.Filter(ItemSource slots, Predicate<ItemStack> filter)
extends Record
implements ItemSource
- Mappings:
Namespace Name named net/minecraft/inventory/ItemSource$Filterintermediary net/minecraft/class_12271$class_12272official dtq$anamed slotsintermediary comp_5163official bnamed filterintermediary comp_5164official c
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.inventory.ItemSource
ItemSource.Filter, ItemSource.Limit, ItemSource.Map -
Field Summary
FieldsModifier and TypeFieldDescriptionThe field for thefilterrecord component.private final ItemSourceThe field for theslotsrecord component.Fields inherited from interface net.minecraft.inventory.ItemSource
EMPTY -
Constructor Summary
ConstructorsConstructorDescriptionFilter(ItemSource slots, Predicate<ItemStack> filter) Creates an instance of aFilterrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.filter()Returns the value of thefilterrecord component.final inthashCode()Returns a hash code value for this object.slots()Returns the value of theslotsrecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.inventory.ItemSource
filter, limit
-
Field Details
-
Constructor Details
-
Method Details
-
itemCopies
- Specified by:
itemCopiesin interfaceItemSource
-
filter
- Specified by:
filterin interfaceItemSource- Mappings:
Namespace Name Mixin selector named filterLnet/minecraft/inventory/ItemSource;filter(Ljava/util/function/Predicate;)Lnet/minecraft/inventory/ItemSource;intermediary method_76129Lnet/minecraft/class_12271;method_76129(Ljava/util/function/Predicate;)Lnet/minecraft/class_12271;official aLdtq;a(Ljava/util/function/Predicate;)Ldtq;
-
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). -
slots
Returns the value of theslotsrecord component.- Returns:
- the value of the
slotsrecord component
-
filter
Returns the value of thefilterrecord component.- Returns:
- the value of the
filterrecord component
-