Record Class RecipeResult
java.lang.Object
java.lang.Record
de.luckymcdev.foundryengine.common.builder.recipe.RecipeResult
public record RecipeResult(net.minecraft.resources.Identifier id, BiConsumer<net.minecraft.data.recipes.RecipeOutput, net.minecraft.core.HolderLookup.Provider> save)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionRecipeResult(net.minecraft.resources.Identifier id, BiConsumer<net.minecraft.data.recipes.RecipeOutput, net.minecraft.core.HolderLookup.Provider> save) Creates an instance of aRecipeResultrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.net.minecraft.resources.Identifierid()Returns the value of theidrecord component.BiConsumer<net.minecraft.data.recipes.RecipeOutput, net.minecraft.core.HolderLookup.Provider> save()Returns the value of thesaverecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
RecipeResult
public RecipeResult(net.minecraft.resources.Identifier id, BiConsumer<net.minecraft.data.recipes.RecipeOutput, net.minecraft.core.HolderLookup.Provider> save) Creates an instance of aRecipeResultrecord class.- Parameters:
id- the value for theidrecord componentsave- the value for thesaverecord component
-
-
Method Details
-
toString
-
hashCode
-
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). -
id
public net.minecraft.resources.Identifier id()Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
save
public BiConsumer<net.minecraft.data.recipes.RecipeOutput, net.minecraft.core.HolderLookup.Provider> save()Returns the value of thesaverecord component.- Returns:
- the value of the
saverecord component
-