Record Class UShapedRecipeSerializer.ShapedRecipeValues
java.lang.Object
java.lang.Record
info.u_team.u_team_core.recipeserializer.UShapedRecipeSerializer.ShapedRecipeValues
- Enclosing class:
- UShapedRecipeSerializer<T extends net.minecraft.world.item.crafting.ShapedRecipe>
protected static record UShapedRecipeSerializer.ShapedRecipeValues(int width, int height, net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> recipeItems, net.minecraft.world.item.ItemStack result, net.minecraft.resources.ResourceLocation id, String group, net.minecraft.world.item.crafting.CraftingBookCategory category, boolean showNotification)
extends Record
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedShapedRecipeValues(int width, int height, net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> recipeItems, net.minecraft.world.item.ItemStack result, net.minecraft.resources.ResourceLocation id, String group, net.minecraft.world.item.crafting.CraftingBookCategory category, boolean showNotification) Creates an instance of aShapedRecipeValuesrecord class.ShapedRecipeValues(net.minecraft.world.item.crafting.ShapedRecipe shapedRecipe) -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.world.item.crafting.CraftingBookCategorycategory()Returns the value of thecategoryrecord component.final booleanIndicates whether some other object is "equal to" this one.group()Returns the value of thegrouprecord component.final inthashCode()Returns a hash code value for this object.intheight()Returns the value of theheightrecord component.net.minecraft.resources.ResourceLocationid()Returns the value of theidrecord component.net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient>Returns the value of therecipeItemsrecord component.net.minecraft.world.item.ItemStackresult()Returns the value of theresultrecord component.booleanReturns the value of theshowNotificationrecord component.final StringtoString()Returns a string representation of this record class.intwidth()Returns the value of thewidthrecord component.
-
Constructor Details
-
ShapedRecipeValues
public ShapedRecipeValues(net.minecraft.world.item.crafting.ShapedRecipe shapedRecipe) -
ShapedRecipeValues
protected ShapedRecipeValues(int width, int height, net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> recipeItems, net.minecraft.world.item.ItemStack result, net.minecraft.resources.ResourceLocation id, String group, net.minecraft.world.item.crafting.CraftingBookCategory category, boolean showNotification) Creates an instance of aShapedRecipeValuesrecord class.- Parameters:
width- the value for thewidthrecord componentheight- the value for theheightrecord componentrecipeItems- the value for therecipeItemsrecord componentresult- the value for theresultrecord componentid- the value for theidrecord componentgroup- the value for thegrouprecord componentcategory- the value for thecategoryrecord componentshowNotification- the value for theshowNotificationrecord component
-
-
Method Details
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
width
public int width()Returns the value of thewidthrecord component.- Returns:
- the value of the
widthrecord component
-
height
public int height()Returns the value of theheightrecord component.- Returns:
- the value of the
heightrecord component
-
recipeItems
public net.minecraft.core.NonNullList<net.minecraft.world.item.crafting.Ingredient> recipeItems()Returns the value of therecipeItemsrecord component.- Returns:
- the value of the
recipeItemsrecord component
-
result
public net.minecraft.world.item.ItemStack result()Returns the value of theresultrecord component.- Returns:
- the value of the
resultrecord component
-
id
public net.minecraft.resources.ResourceLocation id()Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
group
Returns the value of thegrouprecord component.- Returns:
- the value of the
grouprecord component
-
category
public net.minecraft.world.item.crafting.CraftingBookCategory category()Returns the value of thecategoryrecord component.- Returns:
- the value of the
categoryrecord component
-
showNotification
public boolean showNotification()Returns the value of theshowNotificationrecord component.- Returns:
- the value of the
showNotificationrecord component
-