Record Class ShapedRecipe.Serializer.RawShapedRecipe
java.lang.Object
java.lang.Record
net.minecraft.world.item.crafting.ShapedRecipe.Serializer.RawShapedRecipe
- Enclosing class:
 - ShapedRecipe.Serializer
 
static record ShapedRecipe.Serializer.RawShapedRecipe(String group, CraftingBookCategory category, Map<String,Ingredient> key, List<String> pattern, ItemStack result, boolean showNotification)
extends Record 
- 
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final CraftingBookCategoryThe field for thecategoryrecord component.static final com.mojang.serialization.Codec<ShapedRecipe.Serializer.RawShapedRecipe>private final StringThe field for thegrouprecord component.private final Map<String,Ingredient> The field for thekeyrecord component.The field for thepatternrecord component.private final ItemStackThe field for theresultrecord component.private final booleanThe field for theshowNotificationrecord component. - 
Constructor Summary
ConstructorsConstructorDescriptionRawShapedRecipe(String group, CraftingBookCategory category, Map<String, Ingredient> key, List<String> pattern, ItemStack result, boolean showNotification) Creates an instance of aRawShapedReciperecord class. - 
Method Summary
Modifier and TypeMethodDescriptioncategory()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.key()Returns the value of thekeyrecord component.pattern()Returns the value of thepatternrecord component.result()Returns the value of theresultrecord component.booleanReturns the value of theshowNotificationrecord component.final StringtoString()Returns a string representation of this record class. 
- 
Field Details
- 
group
The field for thegrouprecord component. - 
category
The field for thecategoryrecord component. - 
key
The field for thekeyrecord component. - 
pattern
The field for thepatternrecord component. - 
result
The field for theresultrecord component. - 
showNotification
private final boolean showNotificationThe field for theshowNotificationrecord component. - 
CODEC
 
 - 
 - 
Constructor Details
- 
RawShapedRecipe
RawShapedRecipe(String group, CraftingBookCategory category, Map<String, Ingredient> key, List<String> pattern, ItemStack result, boolean showNotification) Creates an instance of aRawShapedReciperecord class.- Parameters:
 group- the value for thegrouprecord componentcategory- the value for thecategoryrecord componentkey- the value for thekeyrecord componentpattern- the value for thepatternrecord componentresult- the value for theresultrecord 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 '=='. - 
group
Returns the value of thegrouprecord component.- Returns:
 - the value of the 
grouprecord component 
 - 
category
Returns the value of thecategoryrecord component.- Returns:
 - the value of the 
categoryrecord component 
 - 
key
Returns the value of thekeyrecord component.- Returns:
 - the value of the 
keyrecord component 
 - 
pattern
Returns the value of thepatternrecord component.- Returns:
 - the value of the 
patternrecord component 
 - 
result
Returns the value of theresultrecord component.- Returns:
 - the value of the 
resultrecord component 
 - 
showNotification
public boolean showNotification()Returns the value of theshowNotificationrecord component.- Returns:
 - the value of the 
showNotificationrecord component 
 
 -