Record Class CreativeTabContentSupplier.Wrapper
java.lang.Object
java.lang.Record
dev.latvian.mods.kubejs.item.creativetab.CreativeTabContentSupplier.Wrapper
- All Implemented Interfaces:
net.minecraft.world.item.CreativeModeTab.DisplayItemsGenerator
- Enclosing interface:
CreativeTabContentSupplier
public static record CreativeTabContentSupplier.Wrapper(CreativeTabContentSupplier supplier)
extends Record
implements net.minecraft.world.item.CreativeModeTab.DisplayItemsGenerator
-
Constructor Summary
ConstructorsConstructorDescriptionWrapper(CreativeTabContentSupplier supplier) Creates an instance of aWrapperrecord class. -
Method Summary
Modifier and TypeMethodDescriptionvoidaccept(net.minecraft.world.item.CreativeModeTab.ItemDisplayParameters itemDisplayParameters, net.minecraft.world.item.CreativeModeTab.Output output) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.supplier()Returns the value of thesupplierrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Wrapper
Creates an instance of aWrapperrecord class.- Parameters:
supplier- the value for thesupplierrecord component
-
-
Method Details
-
accept
public void accept(net.minecraft.world.item.CreativeModeTab.ItemDisplayParameters itemDisplayParameters, net.minecraft.world.item.CreativeModeTab.Output output) - Specified by:
acceptin interfacenet.minecraft.world.item.CreativeModeTab.DisplayItemsGenerator
-
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). -
supplier
Returns the value of thesupplierrecord component.- Returns:
- the value of the
supplierrecord component
-