Record Class BrewingRecipeRegistry
java.lang.Object
java.lang.Record
net.neoforged.neoforge.common.brewing.BrewingRecipeRegistry
Starting from 1.20.5 this is used to hold 
IBrewingRecipes inside of PotionBrewing.
 For queries, use the vanilla PotionBrewing.
 For registration, use RegisterBrewingRecipesEvent.- 
Field SummaryFieldsModifier and TypeFieldDescriptionprivate final List<IBrewingRecipe> The field for therecipesrecord component.
- 
Constructor SummaryConstructorsConstructorDescriptionBrewingRecipeRegistry(List<IBrewingRecipe> recipes) Creates an instance of aBrewingRecipeRegistryrecord class.
- 
Method SummaryModifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.Returns the output ItemStack obtained by brewing the passed input and ingredient.final inthashCode()Returns a hash code value for this object.booleanReturns true if the passed input and ingredient have an outputbooleanisValidIngredient(ItemStack stack) Returns true if the passed ItemStack is a valid ingredient for any of the recipes in the registry.booleanisValidInput(ItemStack stack) Returns true if the passed ItemStack is a valid input for any of the recipes in the registry.recipes()Returns the value of therecipesrecord component.final StringtoString()Returns a string representation of this record class.
- 
Field Details- 
recipesThe field for therecipesrecord component.
 
- 
- 
Constructor Details- 
BrewingRecipeRegistryCreates an instance of aBrewingRecipeRegistryrecord class.- Parameters:
- recipes- the value for the- recipesrecord component
 
 
- 
- 
Method Details- 
getOutputReturns the output ItemStack obtained by brewing the passed input and ingredient.
- 
hasOutputReturns true if the passed input and ingredient have an output
- 
isValidIngredientReturns true if the passed ItemStack is a valid ingredient for any of the recipes in the registry.
- 
isValidInputReturns true if the passed ItemStack is a valid input for any of the recipes in the registry.
- 
toStringReturns 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.
- 
hashCodepublic 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.
- 
equalsIndicates 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).
- 
recipesReturns the value of therecipesrecord component.- Returns:
- the value of the recipesrecord component
 
 
-